r-hyperspec / hyperSpec

hyperSpec: Tools for Spectroscopy (R package)
https://r-hyperspec.github.io/hyperSpec/
GNU General Public License v3.0
12 stars 3 forks source link

Why "energy" → `invcm`? #62

Closed GegznaV closed 2 years ago

GegznaV commented 3 years ago

In line 123 of code:

https://github.com/r-hyperspec/hyperSpec/blob/a14c9c8830766c77074aad82e16e8351d4e21a93/R/wl_convert_units.R#L123-L125

Why is "energy" converted to invcm (i.e., 1/cm) and not to ev (electronvolts)?

@ximeg, @cbeleites, @bryanhanson, what do you think?

cbeleites commented 3 years ago

I'd say bug. But I'd also say that "energy" is too vague to be of any use - how should a user guess that "energy" is synonymous with electron Volts (when the spectral axis is almost always energy-related)?

BTW: I'd also suggest to not convert "cm" into inverse cm (!)

GegznaV commented 2 years ago

OK, I'd remove "energy" and "cm" from the list of options that are converted to inverted centimeters.

If there are some the reasons why these options should be kept (Does @ximeg know any of them?), I may return them in the future.

GegznaV commented 2 years ago