photobiology 0.9.23

Changes from version 0.9.22, the most recent CRAN release, is:

  • Bug fix: Ensure that getWhenMeasured() always returns an object of class POSIXct. Avoids occasional crashes in ‘PhotobiolgyInOut’.
  • Add scale.factor as formal parameter to methods irrad(), q_irrad(), e_irrad(), response(), q_response() and e_response(). Previous behaviour remains the default.
  • Change default value for parameter idx in the various summary methods for collections of spectra. Also add parameter idx to “add attributes to tibble” methods. The new default argument does not affect the default behaviour of the methods. The change in handling of idx = NULL, the old default might break old code in exceptional cases when idx = NULL was passed explicitly in user code instead of relying on it being the default.
  • Rewrite the “get” methods for attributes using a simpler, and possibly faster approach.
  • Add parameter sep to function convolve_each(). Previous behaviour remains the default.

Documentation web site at includes all help pages, with output from all examples, and vignettes in HTML format.
NOTE: The updated package is in CRAN.

Please raise issues concerning bugs or enhancements to this package through Bitbucket

Some interesting new R packages

Some of the packages that appeared in CRAN during June seem interesting. I haven’t tried them yet but have been listed at the R Views blog in Joseph Rickert’s regular column, which I recommend to anyone wanting to keep up to date on new packages.

  • genesysr: Genesys PGR Client. Access data on plant genetic resources from genebanks around the world published on Genesys (<>).
  • rppo: Access the Global Plant Phenology Data Portal. An R interface to the Global Plant Phenology Data Portal, which is accessible online at <>.
  • spectralAnalysis: Pre-Process, Visualize and Analyse Process Analytical Data, by Spectral Data Measurements Made During a Chemical Process. Infrared, near-infrared and Raman spectroscopic data measured during chemical reactions, provide structural fingerprints by which molecules can be identified and quantified.
  • BiocManager: Access the Bioconductor Project Package Repository. A convenient tool to install and update Bioconductor packages.
  • pkgbuild: Find Tools Needed to Build R Packages. Provides functions used to build R packages. Locates compilers needed to build R packages on various platforms and ensures the PATH is configured appropriately so R can use them.
  • ssh: Secure Shell (SSH) Client for R. Connect to a remote server over SSH to transfer files via SCP, setup a secure tunnel, or run a command or script on the host while streaming stdout and stderr directly to the client.

ggpmisc 0.3.0

A major update to ‘ggpmisc’ (0.3.0) follows availability of the update of ‘ggplot2’ (3.0.0) (see release announcement) and the release of the new package ‘gginnards’ (0.0.1) (see announcement) through CRAN. Package documentation is available at as a web site.

Functions earlier included in ‘ggpmisc’ (< 0.3.0) related to debugging and low level manipulation of ggplot objects have been moved to package ‘gginnards’. The functions that remain in ‘ggpmisc’ (>= 0.3.0) are related to annotation of plots with fitted-model equations, fit diagnosis, ANOVA and summary tables, highlighting and labelling of peaks and valleys in curves, and local density-based highlighting or labelling in scatter plots.  Additionally specializations of the ggplot() constructor allow on-the-fly conversion of time-series and geom_table() makes it possible to add tables to plots respecting the the Grammar of Graphics paradigm.

The enhancements in this update to ‘ggpmisc’ are made possible by changes to ‘ggplot2’ (>= 3.0.0) made while adding support for sf (simple features). Not all extensions to ‘ggplot2’ have been updated yet to be compatible with the new version of ‘ggplot2’ so if you need them, you may need to wait before updating to ‘ggplot2’ (3.0.0) and consequently also before updating to this version of ‘ggpmisc’.

This time I include some example plots taken from the documentation of the package. In all cases annotations are generated automatically, but formatting is flexible. Larger plots are linked to the thumbnails.

Main changes since ‘ggpmisc’ (0.2.17) the previous CRAN release.

  • Add geom_table() a geom for adding a layer containing one or more tables to a plot panel.
  • Add stat_fit_tb() a stat that computes a tidy tabular version of the summary table or ANOVA table from a model fit.
  • Add support for "weight" aesthetic in stat_poly_eq() so that weights can be passed to lm() (fixing bug reported by S.Al-Khalidi).
  • Add support for column selection and renaming to stat_fit_tb().
  • Add new statistic stat_fmt_tb() for formatting of tibbles for addition to plots as tables.
  • Rename stat_quadrat_count() into stat_quadrant_count() (fix miss-spelling).
  • Move debug stats and geoms to package ‘gginnards’.
  • Move plot layer manipulation functions to package ‘gginnards’.
  • Revise vignettes.

NOTE: The new version of ‘ggpmisc’ is on its way to CRAN and should be available for download later in the week.