Functions Supporting Packages ChemoSpec and ChemoSpec2D

Functions supporting the common needs of packages 'ChemoSpec' and 'ChemoSpec2D'.


ChemoSpecUtils 0.2.211 2019-02-28

Bug Fixes

  • chkSpectra.Spectra2D would fail if there was only one sample when checking to see if NAs were present in the same positions across all data sets. Fixed.
  • Replaced code for cosine distance calculation in rowDist. The previous version was giving slightly wrong answers.

ChemoSpecUtils 0.2.204 2018-12-19

Bug Fixes

  • updateGroups now reports the old groups if new.grps = NULL, as intended and claimed in the documentation.

Bug Fixes

  • plotScree now knows what to do with class princomp.

ChemoSpecUtils 0.2.197 2018-12-02

Bug Fixes

  • More changes to .chkArgs since errors were introduced via the most recent "fix"! Updated unit tests for the function, but even more work should be done there. Using HandyStuff::examplePage to look for errors and warnings. None found.

ChemoSpecUtils 0.2.170 2018-11-28

Bug Fixes

  • Fixed a problem in .chkArgs(mode = 13) that was giving an error in ChemoSpec::r_pcaSpectra.

ChemoSpecUtils 0.2.163 2018-11-28


  • Added function updateGroups.

ChemoSpecUtils 0.2.160 2018-11-23

Bug Fixes

  • Fixed a problem with color assignment in .groupNcolor (the problem seems to have been present from the very first version of ChemoSpec). Reported by Reinhard Kerschner (many thanks!).


  • Made check4Gaps gap checking more robust, with better examples and documentation. If no gap found, a data frame with one row is returned. In turn, this required changes over in .binData and binSpectra which are in ChemoSpec. In addition, while check4Gaps still accepts an argument tol no other functions are using it, and a much more suitable default value is computed in check4Gaps rather than being computed in another function and passed here.

ChemoSpecUtils 0.2.142 2018-11-09


  • Consistent argument checking introduced via .chkArgs.

ChemoSpecUtils 0.2.23 2018-10-28


  • Improved sumSpectra output format.
  • removeGroup and removeSample go full S3 dispatch for consistency among the three packages.
  • Unit tests moved from ChemoSpec2D.
  • hcaScores moved from ChemoSpec and converted to S3 dispatch.

New Features

  • New function chkArgs and associated unit tests added, but it is not yet used in any of the other functions.


Seems to work correctly on behalf of ChemoSpec and ChemoSpec2D devel versions.

ChemoSpecUtils 0.1.62 2018-10-12


  • S3 generics created for chkSpectra, removeFreq, sumSpectra, sumGroups.
  • Removed Additional_repositories field from DESCRIPTION (I was using it incorrectly).
  • Removed Rd cross references to ChemoSpec2D for CRAN, temporarily.

ChemoSpecUtils 0.1.52 2018-10-08


  • Additional_repositories added to DESCRIPTION.
  • Added dependency on ChemoSpec >= 5.0.

ChemoSpecUtils 0.1.44 2018-10-08



ChemoSpecUtils 0.1.43 2018-10-08


  • .groupNcolor added with argument mode.
  • added.

ChemoSpecUtils 0.1.38 2018-10-06


  • General polishing and documentation improvements.

ChemoSpecUtils 0.1.12 2018-10-01


  • Seems to be fully functional with the 5.0 series of ChemoSpec.

ChemoSpecUtils 0.1.1 2018-09-27


  • addLegend gets an example.

ChemoSpecUtils 0.1.1 2018-09-27


  • Package framework & first set of functions.

Reference manual

It appears you don't have a PDF plugin for this browser. You can click here to download the reference manual.


1.0.0 by Bryan A. Hanson, 11 days ago

Report a bug at

Browse source code at

Authors: Bryan A. Hanson [aut, cre] , Tejasvi Gupta [ctb] (author of ggplot2 graphics)

Documentation:   PDF Manual  

GPL-3 license

Imports plyr, ggplot2, ggrepel, plotly, magrittr

Suggests ChemoSpec, ChemoSpec2D, tinytest, robustbase, RColorBrewer, amap, irlba, ThreeWay, multiway, lattice, roxut, reshape2, patchwork

Depended on by ChemoSpec, ChemoSpec2D.

See at CRAN