Skip to content

Shimadzu .spc file load in R #25

@chloefouilloux

Description

@chloefouilloux

Hello,

If you have any time to spare I would be very grateful to receive some guidance with respect to how to load Shimadzu-type .spc files into R. I am new to this community (both coding and spectrophotometry) and any help would be very appreciated!

After reading some of the documentation on GitHub, I have added the "hyperSpec" package to include both :

repos <- c("https://r-hyperspec.github.io/pkg-repo/", getOption("repos"))
install.packages("hySpc.read.txt", repos = repos)
install.packages("hySpc.read.spc", repos = repos)

After loading these new libraries, I've tried to read in a .spc file

hySpc.read.spc::read_spc("EXAMPLE.spc")
Error in .spc_file_hdr(f) : Support for Shimadzu SPC file format (OLE CF) is not yet implemented

I have also tried the txt version

hySpc.read.txt::read_txt_Shimadzu("EXAMPLE.spc")
Error in pos4Li[[i]] <- pos4[tmp] : attempt to select less than one element in integerOneIndex

I have attached an example of the .spc file that I hope to read into R. The overall functionality of hyperSpec seems really cool, so I hope that these files are compatible!

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions