Package: staRdom 1.1.32

Matthias Pucher

staRdom: PARAFAC Analysis of EEMs from DOM

'This is a user-friendly way to run a parallel factor (PARAFAC) analysis (Harshman, 1971) <doi:10.1121/1.1977523> on excitation emission matrix (EEM) data from dissolved organic matter (DOM) samples (Murphy et al., 2013) <doi:10.1039/c3ay41160e>. The analysis includes profound methods for model validation. Some additional functions allow the calculation of absorbance slope parameters and create beautiful plots.'

Authors:Matthias Pucher [aut, cre], Daniel Graeber [aut, ctb], Stefan Preiner [ctb], Renata Pinto [ctb]

staRdom_1.1.32.tar.gz
staRdom_1.1.32.zip(r-4.7)staRdom_1.1.32.zip(r-4.6)staRdom_1.1.32.zip(r-4.5)
staRdom_1.1.32.tgz(r-4.6-any)staRdom_1.1.32.tgz(r-4.5-any)
staRdom_1.1.32.tar.gz(r-4.7-any)staRdom_1.1.32.tar.gz(r-4.6-any)
staRdom_1.1.32.tgz(r-4.6-emscripten)
manual.pdf |manual.html
DESCRIPTION
card.svg |card.png
staRdom/json (API)

# Install 'staRdom' in R:
install.packages('staRdom', repos = c('https://matthiaspucher.r-universe.dev', 'https://cloud.r-project.org'))

Bug tracker:https://github.com/matthiaspucher/stardom/issues

Datasets:
  • eem_list - 15 fluorescence samples from drEEM used for examples.
  • eem_list_outliers - 2 fluorescence samples from drEEM that were excluded as outliers from the PARAFAC model.
  • peaks - Data.frame containing common EEM peaks with the wavelengths and possible deviations
  • pf1 - PARAFAC model, see vignette, unconstrained
  • pf1n - PARAFAC model, see vignette, non-negative constraints
  • pf2 - PARAFAC model, see vignette, non-negative constraints, normalised
  • pf3 - PARAFAC model, see vignette, non-negative constraints, normalised, outliers removed
  • pf4 - PARAFAC model, see vignette, non-negative constraints, normalised, outliers removed, high accuarcy
  • sh - Result from PARAFAC split-half analysis, periodic data split

On CRAN:

Conda:

7.00 score 30 stars 110 scripts 653 downloads 3 mentions 97 exports 116 dependencies

Last updated from:abc3605c8d. Checks:9 OK. Indexed: yes.

TargetResultTimeFilesSyslog
linux-devel-x86_64OK227
source / vignettesOK294
linux-release-x86_64OK225
macos-release-arm64OK167
macos-oldrel-arm64OK186
windows-develOK207
windows-releaseOK173
windows-oldrelOK166
wasm-releaseOK161

Exports:A_missingabs_blcorabs_fit_slopeabs_parmsabsorbance_readeem_absdileem_applyeem_checkdataeem_checksizeeem_correctionseem_csveem_csv2eem_dilcorreem_dilutioneem_duplicateseem_easyeem_eemdileem_excludeeem_exporteem_extend2largesteem_getextremeeem_hitachieem_ife_correctioneem_import_direem_interpeem_is.naeem_load_dreemeem_matmulteem_metatemplateeem_name_replaceeem_overview_ploteem_parafaceem_raman_areaeem_raman_normalisation2eem_rangeeem_read_csveem_red2smallesteem_rem_scateem_scale_exteem_setNAeem_smootheem_spectral_coreem_write_csveem2arrayeempf_bindxceempf_comp_load_ploteempf_comp_mateempf_comp_nameseempf_comp_names<-eempf_compareeempf_comps3Deempf_convergenceeempf_corcondiaeempf_corploteempf_cortableeempf_eemqualeempf_excompeempf_exporteempf_fitseempf_leverageeempf_leverage_dataeempf_leverage_identeempf_leverage_ploteempf_load_ploteempf_mleverageeempf_OF_uploadeempf_openfluoreempf_plot_compseempf_plot_ssccheckeempf_reordereempf_reporteempf_rescaleBCeempf_residualseempf_residuals_metricseempf_residuals_ploteempf_ssceempf_ssccheckeempf_varimpeempf4analysisgeom_eempeaklocgeom_eemregionsgeom_eemscatterggeemggeem_overlaylist_joinmaxlinesnorm_arraynorm2Aparafac_convsplithalfsplithalf_plotsplithalf_splitssplithalf_tccsscssc_maxtcctcc_find_pairs

Dependencies:abindassertthatbackportsBHbitbit64bootbroomcarcarDatacdomclicliprCMLScodetoolscolorspacecowplotcpp11crayondata.tableDerivdoBydoParalleldplyrdrceemRfarverforcatsforeachforecastFormulafracdiffgenericsGGallyggplot2ggstatsgluegridExtragtablegtoolshmsisobanditeratorsjsonlitelabelinglatticelifecyclelme4lmtestmagrittrMASSMatrixMatrixModelsmatrixStatsMBAmgcvmicrobenchmarkminpack.lmminqamodelrmultcompmultiwaymvtnormnlmenloptrnnetnumDerivpatchworkpbkrtestpillarpkgconfigplotrixpracmaprettyunitsprogresspurrrquadprogquantregR.matlabR.methodsS3R.ooR.utilsR6rbibutilsRColorBrewerRcppRcppArmadilloRcppEigenRdpackreadrreformulasrlangrlistS7sandwichscalesSparseMstringistringrsurvivalTH.datatibbletidyrtidyselecttimeDatetzdburcautf8vctrsviridisviridisLitevroomwithrXMLyamlzoo

Correcting raw data, calculating peaks and indices in EEMS and absorbance (slope) parameters
Introduction | Aim of this document | Hint for beginners in R | Starting the analysis using the template | Output parameters | Input parameters | Fluorometer data (EEM) | Photometer data (absorbance) | Meta data | Spectral correction | Write out results and plots | Results table | Plots | Save data to RData file | Data correction | Absorbance baseline correction | Dilution | EEM range reduction | Blank correction | Correct inner filter effects | Remove and interpolate scattering | Raman normalisation | Smoothing | Running the analysis | Installation | R | RStudio | Optional software | Troubleshooting | Peaks table shows NAs | Only some sample plots show peaks | I cannot read csv files in MS Excel | I get error messages concerning my output directory | References

Last update: 2026-02-19
Started: 2018-04-06

PARAFAC analysis of EEM data to separate DOM components in R
Introduction | Aim of this document | Remark on errors and warnings | Install and load staRdom | Parallel processing | Overview of analysis steps | Example data coming with the package | Raw EEM data | Raw absorbance data | Additional raw data | Corrected EEM data | PARAFAC model | Import raw data | Check data | Data preparation and correction | Sample names | Absorbance baseline correction | Spectral correction | Blank subtraction | Inner-filter effect correction | Raman normalisation | Remove blanks from sample set | Remove and interpolate scattering | Correct for dilution | Smooth data | Overview of samples | Peak picking and indices | Absorbance indices | Creating a PARAFAC model | Loading data | Load drEEM example dataset | Sample set wavelength ranges | Find and remove noise in EEM data | Explore dataset | Check the correlation between different components | Find and exclude outliers leverage | Examine residuals | Recalculating the model with increased accuracy | Plot the resulting components and loadings | Plotting samples and residuals | Split-half analysis | Loadings of outliers | Further model validation | Core consistency | EEMqual | Importance of components | Formatting a model | Naming models and components | Sorting components | Model export and interpretation | Comparing your data using openfluor.org | Comparing data using SSC | Creating a report on your analysis | Exporting the model | Combine results and handle dilution issues | Identify peaks visually | Experimental(!) functions | SSCs between initialisations | Recombining components | References

Last update: 2026-02-19
Started: 2018-04-06

Readme and manuals

Help Manual

Help pageTopics
Import EEMs from generic csv files..eem_csv
Add data of a PARAFAC model derived from multiway from EEMs.trans_parafac
Calculate the sample loadings for samples not involved in model buildingA_missing
Baseline correction for absorbance dataabs_blcor
Fit absorbance data to exponential curve. 'drm' is used for the fitting process.abs_fit_slope
Calculating slopes and slope ratios of a data frame of absorbance data.abs_parms
Reading absorbance data from txt and csv files.absorbance_read
Converting EEM data from class eem to data.frame.as.data.frame.eem
Multiply absorbance data according to the dilution and remove absorbance from samples where undiluted data is used.eem_absdil
Applying functions on EEMseem_apply
Check your EEM, absorption and metadata before processingeem_checkdata
Check size of EEMseem_checksize
Return names of samples where certain corrections are missing.eem_corrections
Importer function for generic csv files to be used with eem_read().eem_csv
Importer function for generic csv files to be used with eem_read().eem_csv2
Create table how samples should be corrected because of dilutioneem_dilcorr
Modifying fluorescence data according to dilution.eem_dilution
Check for duplicate sample nameseem_duplicates eem_duplicates.data.frame eem_duplicates.default eem_duplicates.eemlist
Opens an R markdown template for an easy and userfriendly analysis of EEM data.eem_easy
Correct names of EEM samples to match undiluted absorbance data.eem_eemdil
Exclude complete wavelengths or samples form data seteem_exclude
Export all samples of an eem_listeem_export
EEM sample data is extended to include all wavelengths in all sampleseem_extend2largest
Determines the the biggest range of EEM spectrum where data is available from each sample.eem_getextreme
Importer function for Hitachi F-7000 txt files to be used with eem_read().eem_hitachi
Wrapper function to allow eem_inner_filter_effect (eemR) handling different cuvette lengths.eem_ife_correction
Load all eemlist obects saved in different Rdata or RDa files in a folder.eem_import_dir
Missing values are interpolated within EEM dataeem_interp
Check for NAs in EEM dataeem_is.na
15 fluorescence samples from drEEM used for examples.eem_list
2 fluorescence samples from drEEM that were excluded as outliers from the PARAFAC model.eem_list_outliers
Load original data from the drEEM tutorial and return it as eemlisteem_load_dreem
Multiply all EEMs with a matrixeem_matmult
Create table that contains sample names and locations of files.eem_metatemplate
Replace matched patterns in sample nameseem_name_replace
Plot fluorescence data from several samples split into several plots.eem_overview_plot
Runs a PARAFAC analysis on EEM dataeem_parafac
Calculate raman area of EEM sampleseem_raman_area
Wrapper function to eem_raman_normalisation (eemR).eem_raman_normalisation2
Cut EEM data matching a given wavelength rangeeem_range
Import EEMs from generic csv tables (deprecated)eem_read_csv
Remove wavelengths, that are missing in at least one sample form the whole set.eem_red2smallest
Remove Raman and Rayleigh scattering in fluorescence dataeem_rem_scat
Determine the range of fluorescence values in a set of sampleseem_scale_ext
set parts of specific samples to NA and optionally interpolate these partseem_setNA
Smooth fluorescence data by calculating rolling mean along excitation wavelengths.eem_smooth
Multiply EEMs with spectral correction vectors (Emission and Excitation)eem_spectral_cor
Export samples in an EEM list to a single csv fileseem_write_csv
Data from an eemlist is transformed into an arrayeem2array
Combining extracted components of PARAFAC modelseempf_bindxc
Plot components from a PARAFAC modeleempf_comp_load_plot
Extract EEM matrix for single components determined in the PARAFAC analysiseempf_comp_mat
Extract names from PARAFAC model componentseempf_comp_names
Set names of PARAFAC componentseempf_comp_names<-
Plot a set of PARAFAC models to compare the single componentseempf_compare
3D plots of PARAFAC componentseempf_comps3D
Extract modelling information from a PARAFAC model.eempf_convergence
Calculate the core consistancy of an EEM PARAFAC modeleempf_corcondia
Plot correlations of components in sampleseempf_corplot
Calculating correlations between the component loadings in all samples (C-Modes).eempf_cortable
Calculating EEMqual which is an indicator of a PARAFAC model's qualityeempf_eemqual
Extracting components of a PARAFAC modeleempf_excomp
Create one table containing the PARAFAC models factors and optionally exporting it to csv or txteempf_export
Fits vs. components of PARAFAC models are plottedeempf_fits
Calculate the leverage of each emission and excitation wavelength and each sample from a single PARAFAC modeleempf_leverage
Combine leverages into one data frame and add optional labels.eempf_leverage_data
Plot leverage of emission wavelengths, excitation wavelengths and samples.eempf_leverage_ident
Plot leverage of emission wavelengths, excitation wavelengths and samples.eempf_leverage_plot
Plot amount of each component in each sample as bar ploteempf_load_plot
Calculate the leverage of each emission and excitation wavelength and each sample from a list of PARAFAC modelseempf_mleverage
Upload PARAFAC models to openfluor.orgeempf_OF_upload
Write out PARAFAC components to submit to openfluor.org.eempf_openfluor
Plot all components of PARAFAC modelseempf_plot_comps
Plot results from an SSC checkeempf_plot_ssccheck
Reorder PARAFAC componentseempf_reorder
Create a html report of a PARAFAC analysiseempf_report
Rescale B and C modes of PARAFAC modeleempf_rescaleBC
Calculate residuals of EEM data according to a certain modeleempf_residuals
Calculate residual metrics from a PARAFAC modeleempf_residuals_metrics
Plot samples by means of whole sample, each single component and residuumeempf_residuals_plot
Calculate the shift-and shape-sensitive congruence (SSC) between model componentseempf_ssc
Check SSCs between different models or initialisations of one modeleempf_ssccheck
Calculate the importance of each component.eempf_varimp
Create table of PARAFAC components and (optionally) EEM peaks and indices as well as absorbance slope parameters.eempf4analysis
Mark common EEM peaksgeom_eempeakloc
Mark common reagions to EEMs to show molecular groupsgeom_eemregions
Mark EEM scatter bandsgeom_eemscatter
EEM spectra plotted with ggplot2ggeem ggeem.data.frame ggeem.default ggeem.eem ggeem.eemlist ggeem.parafac
Add layers of scatter bands, molecular regions and common peaks to EEM plotsggeem_overlay
Full join of a list of data frames.list_join
Extract data from emission and excitation wavelengths of the components of a PARAFAC model (scaled B- and C-modes)maxlines
Normalise 3-dimensional array in first and second dimensionnorm_array
Compensate for normalisation in C-modesnorm2A
Calculate a PARAFAC model similar to and using 'parafac'.parafac_conv
data.frame containing common EEM peaks with the wavelengths and possible deviationspeaks
PARAFAC model, see vignette, unconstrainedpf1
PARAFAC model, see vignette, non-negative constraintspf1n
PARAFAC model, see vignette, non-negative constraints, normalisedpf2
PARAFAC model, see vignette, non-negative constraints, normalised, outliers removedpf3
PARAFAC model, see vignette, non-negative constraints, normalised, outliers removed, high accuarcypf4
result from PARAFAC split-half analysis, periodic data splitsh
Running a Split-Half analysis on a PARAFAC modelsplithalf
Plot results from a splithalf analysissplithalf_plot
Extracting a list of sample names in each subsample from a splithalf analysissplithalf_splits
Extracting TCC values from a splithalf analysissplithalf_tcc
Calculate the shift-and shape-sensitive congruence (SSC) between two matricesssc
Calculate the combination of components giving the maximum of geometric mean of TCCsssc_max
Caluclate Tucker's Congruence Coefficient of PARAFAC componentstcc
Reorders components of different PARAFAC models according to best fit (TCC)tcc_find_pairs