photobiology 0.8.7 (new functionality and bug fixes)

Numerous small bug fixes, mostly minor.
Rename f_mspct() to msdply() to respect name conventions in common use.
Add mslply() and msaply().
Implement operators %/% and %%, and function abs() for spectra.
Update documentation. Revise titles of help files.

NOTE: Sources, and Windows binaries only for R 3.2.x, are now available in the repository.


photobiology 0.8.6 (new functionality and bug fixes)

Bug fixes related to imports from other packages.
Rename mutate_mspct() to msmsply() to respect name conventions in common use.
Add constructor chroma_spct().
Update documentation.

photobiologySun 0.3.6 (new data)

Add irradiance example time-series data.

NOTE: Sources, and Windows binaries only for R 3.2.x, are now available in the repository.


photobiology 0.8.5 (new functionality and bug fixes)

Implement extract and replacement “indexing” methods for collections of spectra.
(Please, let me know if you encounter any errors with these methods, as some testthat tests give infinite recursion errors that I cannot reproduce outside testthat.)

Implement combine method c() for collections of spectra.

Add function convolve_each().

Add helper function shared_member_class().

photobiologySun 0.3.5 (bug fix)

Rebuild with photobiology 0.8.5.

photobiologyLEDs 0.3.2 (bug fix)

Trim Norlux data to 250..900 nm, and add source_mspct object for this multi-channel array.

Rebuild data and the package with photobiology 0.8.5.

photobiologyPlants 0.3.2 (bug fix)

Set spectral absorbance data type for photoreceptors as "internal".

Fix minor error in UVR8 data.

Rebuild all data and the package under photobiology 0.8.5.

BACKWARDS COMPATIBILITY: Internal changes to attributes in objects of  generic_mspct and derived classes are not 100% backwards compatible, but should be of little consequences to most users. No changes to user code are needed, but objects containing collections of spectra created with versions 0.8.0 to 0.8.4 may need to be rebuilt.

NOTE: Sources, and Windows binaries only for R 3.2.x, are now available in the repository.


photobiology 0.8.4 (new functionality and minor bug fixes)

Expand sun.spct and sun.daily.spct down to 280 nm with zeros.

Add methods for construction of collections of spectra from data frames with different spectra in side-by-side columns (‘untidy’ or wide data): split2source_mspct(), split2response_mscpt(), split2filter_mspct(), split2reflector_mspct(), and split2cps_mspsct().

Add function subset2mspct() for construction of collections of spectra from data frames with spectral data for different spectra in a single column (‘tidy’ or long data), and spectral objects containing several spectra, such as those returned by function rbindspct().

Add print() method for collections of spectra.

Fix minor bug in trim_spct() which was inserting ‘hinges’ on head and/or tail expansion even if use.hinges was set to FALSE.

Fix bug in rare borderline cases where NA was being returned instead of empty spectral objects (objects with zero rows) as is normal practice in R.

photobiologySun 0.3.4 (new data)

Add a collection of spectra giving a time series of a sunfleck under silver birch trees as object gap.mspct data.

NOTE: Sources, and Windows binaries only for R 3.2.x, are now available in the repository.

Old repository at mv.helsinki.fi closed

For several months the main repository for the packages has been located at https://www.r4photobiology.info/R but the old repository remained available. From today the old repository has closed. So, if you were still using it, you will need to switch to the new address. Apart for their URL the repositories have been identical until a couple of weeks ago when I stopped updating the contents of the old repository.


photobiology 0.6.8

Functions sunrise_time(), noon_time(), sunset_time(), day_length(),night_length()andday_night()gain formal parameter‘unit.out’`,
but its default value preserves earlier behaviour.

New generic functions peaks() and valleys().

subset() methods for spectral objects gain a new parameter 'idx'. (This a workaround until a way of wrapping [ operator from data.table is found.) During subsetting, tags are removed from the returned spectrum.

Functions is.photon_based(), is.energy_based(), is.absorbance_based() and is.transmittance_based() have been renamed by replacing the dot with an underscore for consistency with other functions not test for object class.

Fixed bug in trim_waveband().

photobiologygg 0.3.4

annotate_plot() now passes arguments 'angle', 'hjust' and 'vjust' to annotate_waveband() in the case of labels.

NOTE: Sources, and Windows binaries for R 3.1.x and R 3.2.x, are now available in the repository.

Handbook on photobiological calculations with R

A handbook on how to do calculations used in photobiological research with R is under preparation. The handbook will describe the use of our suite of R packages and also of functions from base R and packages from CRAN. Authors are Andreas Albert, Titta Kotilainen and myself. Further details, and possibly an early draft for download will be soon available.

UseR!2015 Conference in Aalborg

useR! logo

I will give a talk at the UseR! conference describing the packages. This will be the first public announcement of the packages, as I consider that the packages, although still under development are now ready for testing by a broader audience and careful use in research and other non-life- or health-threatening measurements and data analysis.

The abstract is available at: http://user2015.math.aau.dk/contributed_talks#153

The presentation slides will be available for download after the conference.


I have updated all the packages in the suite. This is the result testing and programming during recent weeks.

photobiology 0.5.15

New functions normalize() and rescale() for spectra. Both functions set object attributes to flag the spectra that have been modified, and no longer are expressed in absolute units. In addition, tests were added to summary functions to disallow use of rescaled or normalized spectral data as input, with the exception of function integrate_spct().

Function rbindspct() was revised to issue a warning when only some of the spectral objects are rescaled or normalized.

Changes in the code for handling ‘time.unit‘, ‘Tfr.type‘ and ‘Rfr.type‘ attributes.
Added new functions getTimeUnit()getTfrType() and getRfrType().

New test cases were added.

photobiology 0.5.14 (not released)

New class and methods added: object.spct, with the corresponding as.object.spct(), is.object.spct(), setObjetcSpct(), and check.object.spct() functions. Also functions reflectance() and transmittance() are implemented. New function absorptance() is implemented only for object.spct objects. Objects of this class can be used to store corresponding spectral transmittance and spectral reflectance values. No operators are defined for this class as they would be ambiguous. The class attribute needs to be changed to either filter.spct or reflector.spct before using operators, however, no data is lost in the process, or written except for the class attribute, so the class can be changed back to object.spct if needed.

New function added: merge.generic.spct() is a wrapper on merge.data.table() that sets the correct class to the returned merged spectra, preserves attributes used with .spct objects and by default merges by w.length.

photobiologygg 0.2.8

Revised to use new getTimeUnit() and getTfrType() functions from package photobiology 0.5.15 which is now required. New annotation type: the string "title" in the annotations parameter of the plot() functions adds an automatic title to the plot.

photobiologygg 0.2.7 (not released)

Implemented plot() for object.spct objects. Updated User Guide accordingly. Added function multiplot() based on multiplot() example by Winston Chan in his Cookbook for R.

photobiologyFilters 0.2.4

Added data for Petri dishes.

photobiologyFilters 0.2.3

To avoid problems with conversions from spectral transmittance to spectral absorbance and taking into account that what can be really measured is that transmittance is below the detection limit of the instrument used, the minimum value of fractional transmittance has been forced to be 1E-5, with the meaning of 1E-5, consistently with the earlier encoding used for Schott optical glass filters.

photobiologyLEDs 0.2.2

Added data for UVMAX LEDs.

photobiologyPlants 0.1.0

New package combining the functions and data in the old photobiologyPhy and photobiologyCry packages and adding data on optical properties of plant leaves.

Edits to the other packages are related to documentation and in some cases rebuilding of example data with the current version of package photobiology.

NOTE: Sources, and Windows binaries for R 3.1.x, are now available in the repository.


photobiology 0.5.11

Minor enhancement to improve interaction with package data.table

Function irrad() which is also the building block for other “irrad” and “ratio” functions now checks whether the data.table underlying the spectral object is locked and if locked makes a copy before continuing.

This makes is possible to use .SD as argument to these functions when traversing a spectrum object (containing several spectra, or “tagged” regions) using data.table syntax.

NOTE: Sources, and Windows binaries for R 3.1.x, are now available in the repository.


photobiology 0.5.10

This is a bug fix. Wrote test cases for operators and math functions which resulted in me finding several minor bugs which rendered some conbinations of operands non-functional.

Backwards compatible.

NOTE: Sources, and Windows binaries for R 3.1.x, are now available in the repository.

photobiology 0.5.9 (not released but changes included in 0.5.10)

Fixed a major bug in binary operators code for non-transitive operations, triggered
when the first operand is numeric.

Added missing features (bug fix?)

Updated operators’ code so that unary ‘-‘ and unary ‘+’ now work for spectra.

Rewrote the code for math functions, removing redundancy, and adding support for
chroma.spct objects.

Edited the constructors of spct objects so that they recognize additional variable names
for the input data, and rename them.

Updated documentation:

Added a table to the User Guide summarizing the valid and invalid binary operations, and
a second table listing unary operators and math functions.

Added warning messages informing of forbidden operations between dissimilar spectral objects and between spectral objects and wavebands are attempted.

Backwards compatible.