Skip to content

Latest commit

 

History

History
685 lines (504 loc) · 28.2 KB

File metadata and controls

685 lines (504 loc) · 28.2 KB

Changes in version 1.1.2.9000-38 (2026-03-10)

Breaking changes

More information on these changes are available at https://replay.geog.uni-heidelberg.de/REPLAY-website/post/2026/01/upcoming-breaking-changes-in-luminescence/.

  • All import functions will now always append the detector used to the recordType slot of the RLum.Data.Curve object generated, for consistency with what has always been done by read_XSYG2R(). The following functions have been modified to support this new behaviour:

    • read_Daybreak2R()
    • read_PSL2R()
    • read_RF2R()
    • read_SPE2()
    • Risoe.BINfileData2RLum.Data.Curve() In most cases, this is the string “(PMT)” for BIN/BINX, PSL and Daybreak files; in the remaining cases the string “(NA)” is appended. The following example files have been updated to reflect these changes:
    • ExampleData.RLum.Analysis
    • ExampleData.portableOSL As a consequence of these changes, default titles for curve plots will now also contain the detector string. This may potentially disrupt code that uses strict equality (==) when selecting curves based on their recordType (#1275, #1286).
  • Function read_XSYG2R() will now prepend an underscore to the recordType slot of the RLum.Data.Curve object generated from an XSYG file for all objects after the first curve in a record. This will allow an easier way to differentiate the curves to analyse (for example, “OSL (UVVIS”) from those that are not useful in the analysis (for example, “_OSL (NA)“) (#1276).

  • The @info slot returned by function read_XSYG2R() no longer contains a name field: this has been replaced by sequenceName, to differentiate it from the newly-added recordName (#1239, #1387).

  • Functions calc_OSLLxTxRatio(), calc_OSLLxTxDecomposed(), calc_TLLxTxRatio() and analyse_SAR.TL() return two extra columns, SN_RATIO_LnLx and SN_RATIO_TnTx, in their result object. This may disrupt code that relies on column indices instead of column names (#1281, #1330, #1436).

New functions

  • normalise_RLum(): This function enables a fast normalisation of RLum.Data.Curve-class, RLum.Data.Spectrum-class, RLum.Data.Image-class and their combination in RLum.Analysis-class objects. Normalisation was already possible for plotting (e.g., plot_RLum.Data.Curve(…, norm = TRUE)), which uses an internal function called .normalise_curves() to do the job. With normalise_RLum() we expose this functionality to RLum-class objects and enable a convenient normalisation of values that might come in handy in same cases. Normalised values are only count values. Currently implemented is normalisation via keywords, such as "max", "min", "first", "last", "huot", "intensity". Additionally, the function supports normalisation to a positive number (#1250 by @RLumSK, #1300).

  • read_BINXLOG2R(): This function enables you to salvage log files created by a Risø reader into R as RLum.Analysis-class. The function also allows the export of these files into a BIN/BINX format. While the function has been tested on a few examples, it is important to note that log files are not a well-defined data format. This function is intended for use in cases where you have a corrupted BIN/BINX file but a complete log file is still available. Supported log formats are TL, OSL, and OSL curves. All other formats are ignored (#1241 by @RLumSK; thanks to Michael Kenzler for bringing this to our attention).

Removed functions and deprecations

  • Functions github_branches(), github_commits(), github_issues(), is.RLum(), is.RLum.Analysis(), is.RLum.Data(), is.RLum.Data.Curve(), is.RLum.Data.Image(), is.RLum.Data.Spectrum() and is.RLum.Results() (deprecated since 1.1.2) have been removed (#1242).

  • Function install_DevelopmentVersion() has been removed as it relied on the now deprecated devtools::install_github(). Equivalent functionality is available via pak::pkg_install("R-Lum/Luminescence") (#1453).

Bugfixes and changes

analyse_Al2O3C_CrossTalk()

  • The signal_integral argument was silently ignored (#1428).

  • The function now supports the integral_input argument, which can be set to either "channel" (default) and "measurement". When the latter is used, the integrals can be specified in terms of seconds, in which case the function performs an automatic conversion to channels (#1396).

analyse_Al2O3C_ITC()

  • The function used to output a suppressed error message instead of validating the input ahead of that (#1256).

  • The signal_integral argument was silently ignored (#1428).

  • The function now supports the integral_input argument, which can be set to either "channel" (default) and "measurement". When the latter is used, the integrals can be specified in terms of seconds, in which case the function performs an automatic conversion to channels (#1396).

analyse_Al2O3C_Measurement()

  • The function now supports the integral_input argument, which can be set to either "channel" (default) and "measurement". When the latter is used, the integrals can be specified in terms of seconds, in which case the function performs an automatic conversion to channels (#1396).

analyse_baSAR()

  • The function has been updated to use fit_DoseResponseCurve() and plot_DoseResponseCurve() instead of plot_GrowthCurve(). This should not have any visible difference other than the renaming of two arguments: output.plot has been renamed to plot_drc, while output.plotExtended has been renamed to plot_extended. The older names will still work but generate a deprecation warning (#1244).

  • Arguments signal.integral, background.integral, signal.integral.Tx and background.integral.Tx have been renamed to signal_integral, background_integral, signal_integral_Tx and background_integral_Tx, respectively. The older names will still work but generate a deprecation warning (#1290).

  • The function no longer crashes if aliquot_range specifies non-positive indices or if source_doserate = 0 (#1424, #1426).

analyse_FadingMeasurement()

  • The plots were affected by a bug in plot_RLum.Analysis(), so that the output was unnecessarily split over two pages (#1247).

  • Arguments signal.integral and background.integral have been renamed to signal_integral, background_integral, respectively. The older names will still work but generate a deprecation warning (#1290).

  • The function now supports the integral_input argument, which can be set to either "channel" (default) and "measurement". When the latter is used, the integrals can be specified in terms of seconds, in which case the function performs an automatic conversion to channels (#1396).

analyse_IRSAR.RF()

  • The slide$squared_residuals field of the @data slot in the RLum.Results object returned by the function is no longer a 1-column matrix, but a plain numeric vector (#1254).

analyse_pIRIRSequence()

  • Arguments signal.integral.min, signal.integral.max, background.integral.min and background.integral.max have been replaced by signal_integral and background_integral: each of them now defines a vector of channels for the respective integrals. The older names will still work but generate a deprecation warning (#1290).

  • The function crashed if called on an empty list (#1372).

  • The function now supports the integral_input argument, which can be set to either "channel" (default) and "measurement". When the latter is used, the integrals can be specified in terms of seconds, in which case the function performs an automatic conversion to channels (#1396).

analyse_portableOSL()

  • Argument signal.integral has been renamed to signal_integral. The older name will still work but generates a deprecation warning (#1290).

  • The function now supports the integral_input argument, which can be set to either "channel" (default) and "measurement". When the latter is used, the integrals can be specified in terms of seconds, in which case the function performs an automatic conversion to channels (#1396).

analyse_SAR.CWOSL()

  • If mode = "alternate", the dose value is no longer reset automatically. If the first dose point was > 0, the function detected a dose-recovery test and automatically reset this dose point to 0. While this is likely convenient in 9 out of 10 cases, it caused trouble if the mode = "alternate" (passed on to fit_DoseResponseCurve()) because it modified the first dose point and this required additional handling afterwards. Please keep in mind that you have to redefine the recuperation reference in such a case: this is wanted and not a bug (fixed in commit 9ff29bf).

  • The order of columns in the rejection.criteria data frame that is output by the function has been changed so that the UID column appears now first. This is meant to facilitate seeing visually to what aliquot each criteria belongs to. While the UID values are random-looking alphanumeric values, they can identify univocally an aliquot also after merge operations (#1172).

  • A new argument, dose_rate_source, was added to allow users to specify a value for the source dose rate and display values in Gy, rather than seconds. Previously, this was only possible by using a factor with the dose.points argument. However, setting it manually was particularly inconvenient if the dose points were already extracted automatically, as it required users to insert dose values manually regardless of the automated extraction. This argument is also available in other functions that wrap around analyse_SAR.CWOSL() (fixed in commit 4fc985d).

  • The function warns if the most common curve type (which is the one used in the analysis) matches multiple record types, as this may be a sign that the user has forgotten to select the correct set of curves to analyze (#1269).

  • A new signal-to-noise ratio rejection criterion has been added, with default threshold of 50 (controllable by setting the sn.ratio parameter in the rejection.criteria list to a different value). By default it uses the signal-to-noise value computed for the natural curve, but a different curve can be specified via the sn_reference parameter in the rejection.criteria list (#1284).

  • Arguments signal.integral.min, signal.integral.max, background.integral.min and background.integral.max have been replaced by signal_integral, background_integral, signal_integral_Tx and background_integral_Tx: each of them now defines a vector of channels for the respective integrals. The older names will still work but generate a deprecation warning (#1290).

  • When rejection criteria are set to NA, in the plot we now only show the value calculated (say, 1.1) instead of incorrectly showing NAs for both the sign and the threshold (as in 1.1 NA NA) which would look ugly and confusing (#1318).

  • The rejection criteria for the highest dose points was not considered correctly, and in most cases validated to "FAILED" even for thresholds set to NA or Inf (fixed in commit 3562bca).

  • It is now possible to consider value uncertainties in the computation of some rejection criteria (currently only recycling.ratio, recuperation.rate and exceed.max.point) by setting consider.uncertainties = TRUE in the rejection.criteria list. This is disabled by default to preserve existing behaviour (#1325).

  • The function now supports setting background_integral = NA, in which case no background integral is subtracted (#1385; thanks to Annette Kadereit for reporting).

  • If the function processes a list of objects, as is the typical scenario, the aliquot number (not the position number) is returned. The aliquot number represents the consecutive number of objects processed.

  • Add support to control the legend size and the legend symbols via legend.cex and legend.pch (fixed in commit 9ec687d).

  • The function now supports the integral_input argument, which can be set to either "channel" (default) and "measurement". When the latter is used, the integrals can be specified in terms of seconds, in which case the function performs an automatic conversion to channels (#1396).

  • When OSL.component is specified, the function now checks that the input object was actually processed by OSLdecomposed::RLum.OSL_decomposition(), in order to return a warning message when that is not the case (#1464).

  • Curves with recordType starting with _ are automatically removed. This allows to analyse an XSYG file directly without (in many cases) any manual intervention required. This behaviour can be changed by setting argument method_control = list(auto_curve_removal = FALSE) (#1468).

analyse_SAR.TL()

  • Argument signal.integral has been renamed to signal_integral. The older name will still work but generate a deprecation warning (#1290).

  • The integral_input argument now accepts options “channel” (as before) and “measurement” (instead of “temperature”). This was done to uniform the choices accepted by the argument throughout the package. The older name will still work but generates a deprecation warning (#1396).

apply_EfficiencyCorrection()

  • The function no longer produces an invalid object when the interpolation range is outside of the wavelength range of the RLum.Data.Spectrum object (#1402).

calc_AverageDose()

  • The RLum.Results returned now contains a $data field to store the input data for consistency with similar functions, and two columns have been appended to the end of the $summary field for internal use (#1455).

calc_CobbleDoseRate()

  • Argument input has been renamed to object. The older name will still work but generates a deprecation warning (#1434).

calc_CommonDose()

  • The function incorrectly disallowed setting sigmab > 1 when log = FALSE due to excessively strict input validation (#1343).

calc_FiniteMixture()

  • The function didn’t allow inputs such as n.components = 1:3, enforcing the usage of n.components = 2:3 instead. This check, added in v1.1.0, was unnecessarily stringent and has been reverted (#1458).

calc_gSGC()

  • The function no longer crashes in n.MC is set to 0 (#1327).

calc_MaxDose()

  • The De estimates produced when bootstrap = TRUE were not transformed back to the original scale before being returned to the user (#1351).

calc_MinDose()

  • The function now set non-positive De values to NA when log = TRUE, which used to lead to a crash when combined with bootstrap = TRUE (#1313).

  • The bootstrap results stored in the @data$bootstrap$pairs$gamma matrix are now correctly converted to the normal scale for log models. This fixes a regression introduced in v1.0.0, which caused those values to be stored in the log scale (#1345).

  • The function now stores the bootstrap results in the summary slot when bootstrap = TRUE. Moreover, summary results are printed to the terminal also when using bootstrap (#1336; thanks to @feldsparlover and Arindam Biswas for reporting).

  • The function crashed when bootstrapping with bs.N = 1. Now the bs.N parameter is silently reset to 2 in that case, although such low values are discouraged as they may trigger a warning during loess fitting (#1355).

  • The computation of frequencies of bootstrap replicates has been fixed to be sample-wise, while before it was mistakenly computed as a cumulative sum over all samples. In our tests, the difference in results produced by the two implementations appears to be minimal (#1374).

calc_OSLLxTxDecomposed()

  • The data frame returned by the function now contains two additional columns, SN_RATIO_LnLx and SN_RATIO_TnTx (containing NA) for consistency with the output produced by calc_OSLLxTxRatio() (#1330).

calc_OSLLxTxRatio()

  • The data frame returned by the function now contains two additional columns, SN_RATIO_LnLx and SN_RATIO_TnTx. This is the signal-to-noise ratio for the respective shine-down curves for Lx and Tx (#1281).

  • Arguments signal.integral, background.integral, signal.integral.Tx and background.integral.Tx have been renamed to signal_integral, background_integral, signal_integral_Tx and background_integral_Tx, respectively. The older names will still work but generate a deprecation warning (#1290).

  • The function can now accept lists for its Lx.data and Tx.data arguments, in which case it will self-call. This can simplify using the function, as it’s no longer necessary to write a loop to process all records (#1299).

  • The function now supports setting signal_integral to a chosen set of channels while setting background_integral = NA. In this case, no background integral is subtracted and the error calculation and the signal-to-noise ratio will report NA values (#1375).

  • The function now supports the integral_input argument, which can be set to either "channel" (default) and "measurement". When the latter is used, the integrals can be specified in terms of time or temperature, in which case the function performs an automatic conversion to channels (#1396).

calc_TLLxTxRatio()

  • Argument signal.integral has been renamed to signal_integral. The older name will still work but generate a deprecation warning (#1290).

  • The function now supports the integral_input argument, which can be set to either "channel" (default) and "measurement". When the latter is used, the integrals can be specified in terms of temperature, in which case the function performs an automatic conversion to channels (#1396).

combine_De_Dr()

  • The function crashed if the Age_range argument contained missing values (#1378).

convert_CW2pHMi() and convert_CW2pPMi()

  • The function now checks if the results of the approximation step are not valid because all points lie outside of the computed interpolation range, which can happen if the input data is misspecified (#1295).

correct_PMTLinerarity()

  • The function, introduced in v1.1.2, unintentionally came with a major flaw, in that it did nothing on a single RLum.Data.Curve() object (fixed in commit 1d978cf).

  • If the channel resolution was not changing, the function produced NaN values even in cases where dead time was not corrected (fixed in commit 1d978cf).

convert_Concentration2DoseRate()

  • Argument input has been renamed to object. The older name will still work but generates a deprecation warning (#1434).

  • The interpolation of attenuation values has been corrected so that it will not unexpectedly fail if a non-integer value for the grain size is provided, as long as it’s in the valid range (#1444; thanks to Christina Neudorf for reporting).

convert_CW2p*()

  • Argument values has been renamed to object. The older name will still work but generates a deprecation warning (#1434).

convert_Second2Gray()

  • The dose_rate argument is now better validated (#1439).

convert_SG2MG()

  • The function crashed if used on an object resulting from a subset operation, as it used the rownames (which may no longer correspond to row indices) to index into the METADATA slot (#1415).

  • The function now exits cleanly instead of crashing if more than one input filenames are provided (#1446).

extract_IrradiationTimes()

  • The function no longer crashes if the input object contains no position field in its info object (#1466).

fit_CWCurve()

  • Argument values has been renamed to object. The older name will still work but generates a deprecation warning (#1434).

fit_DoseResponseCurve()

  • The C++ implementation of the GOK function has been tweaked to avoid some repeated computations in a loop. Given the different ordering of computations (although mathematically equivalent), there will be small differences in the numerical output when fit.method = "GOK" is used (#1277).

  • The fit message reported is now also stored in the @info slot of the object returned by the function (#1362).

  • The function now consistently returns the material specific parameter R for OTOR and OTORX and its uncertainty (fixed in commit 9b4d6bd).

fit_LMCurve()

  • Arguments values and values.bg have been renamed to object and object.bg, respectively. The older names will still work but generate a deprecation warning (#1434).

  • The function now checks that the number of data points provided is large enough to fit the requested number of components (#1448).

get_RLum()

  • An internal optimization increased the performance of the function by over 50% in some particular cases, such as when merging a large number of RLum.Analysis object (#1271).

merge_RLum.Risoe.BINfileData()

  • Argument input.objects has been renamed to objects. The older name will still work but generates a deprecation warning (#1434).

merge_RLum.Data.Spectrum()

  • The function no longer warns unnecessarily if the RLum.Data.Spectrum object contains no column names (#1450).

plot_AbanicoPlot()

  • When the input data is an RLum.Results object generated by calc_AverageDose(), calc_CentralDose(), calc_MaxDose(), calc_MinDose() or calc_FiniteMixture(), one or more lines (and corresponding labels) for the relevant results will be automatically drawn, unless explicitly suppressed by setting line = NA (#1452).

plot_DetPlot()

  • When operating on a list with the default setting of multicore = TRUE, the function limits the size of the parallel cluster to the number of list elements to process (#1258).

  • Arguments signal.integral.min, signal.integral.max, background.integral.min and background.integral.max have been replaced by signal_integral, background_integral, signal_integral_Tx and background_integral_Tx: each of them now defines a vector of channels for the respective integrals. The older names will still work but generate a deprecation warning (#1290).

  • The function now supports the integral_input argument, which can be set to either "channel" (default) and "measurement". When the latter is used, the integrals can be specified in terms of seconds, in which case the function performs an automatic conversion to channels (#1396).

plot_DRTResults()

  • Argument values has been renamed to object. The older name will still work but generates a deprecation warning (#1434).

plot_RLum.Analysis()

  • The ability to combine multiple plots on a single page regressed in v1.1.2, causing plots intended to appear side-by-side to be rendered on separate pages (#1247).

plot_RLum.Data.Curve()

  • The scaling of the subtitle by cex didn’t account of the par.local argument, thus affecting curve plots generated by plot_RLum.Analysis() (#1347).

plot_RLum.Data.Spectrum()

  • The norm argument is no longer limited to just "min" and "max" but now supports all options provided by normalise_RLum() (#1303).

  • The function now returns NULL (instead of producing an empty plot or crashing) whenever the normalisation step replaces all values with zeroes, which can happen if the normalisation term used is 0, for example when the bg.spectrum argument is used and norm = "min" (#1305).

  • Setting log = "z" will produce a warning if the data contains non-positive values (for example after background subtraction or normalisation) before setting those values to NA. This avoids producing infinities or NaN values that would lead to crashes for some plot types (#1307).

plot_FilterCombinations()

  • The interactive mode did not accept all plotting options from the default (non-interactive) mode (fixed in commit c27a656).

  • If the function was used on a shiny server, the plot showed only after the app was closed (fixed in commit c27a656).

plot_GrowthCurve()

  • Argument sample has been renamed to object. The older name will still work but generates a deprecation warning (#1434).

plot_KDE()

  • The length of the ticks for the rugs is now scaled by the size of dataset, so that visually the rug appears identical any dataset size (#1470; thanks to @feldsparlover for reporting).

plot_RadialPlot()

  • If the error column contains zero values, they are reset to the smallest between the non-zero errors in the dataset and 10-9. This avoids a crash when using the argument centrality = "mean.weighted", which is the default for this function (#1314).

  • The weighted median used to compute the central values when centrality = "median.weighted" now uses the precision as weight (similarly to what is done for the weighted mean), while before it incorrectly used the error (#1323).

read_BIN2R()

  • The function could crash if called with do.call() and some particularly odd inputs (#1260).

  • The function now throws an error instead of returning NULL when a file with the wrong extension is read (#1393).

  • The function will now look for files recursively if the path to a directory is provided (#1393).

read_Daybreak2R()

  • The function struggled with variable header lengths (#1262; thanks to @andrzejbluszcz for reporting).

  • The function will no longer crash if the data point entries have more than four columns (thanks to @andrzejbluszcz for reporting).

  • The import of binary .DAT files has been overhauled and made more correct; moreover, the function accepts both .DAT and .dat extensions for binary inputs, and supports DataType=Command records in ASCII files (#1263, #1266; thanks to @andrzejbluszcz for contributing code and datasets).

  • Trying to import multiple files by specifying a directory name failed because the generated path missed a directory separator (#1264).

read_PSL2R()

  • The function now returns NULL instead of throwing an error if a directory is provided and no PSL files are found within it (#1393).

read_RF2R()

  • The function now throws an error instead of returning NULL if a list containing elements other than character strings is provided (#1393).

read_SPE2R()

  • The function now throws an error instead of returning NULL if the filename provided does not exist (#1393).

read_XSYG2R()

  • Attributes from the record level are now all included in the @info slot, as long as they do not duplicate the attributes from the curve level. Hence, those attributes are now available for filtering (#1239; thanks to @DirkMittelstrass for reporting).

  • The function could crash if called with do.call() and some particularly odd inputs (#1260).

remove_RLum()

  • The function used to add spurious NULL records when an invalid record.id was specified, which in turn could cause a crash when displaying the object to the terminal (#1380).

report_RLum()

  • The function could crash if called with do.call() and some particularly odd inputs (#1260).

subset_SingleGrainData()

  • The function reports an helpful error instead of crashing if the given grains and positions table produces an empty selection (#1412).

Other changes

  • The internal function .normalise_curve() received support to normalise by the minimum value ("min"), the first value ("first"), the channel length ("intensity") or a positive number (e.g, 2.2). These new settings are automatically available to plot_RLum.Analysis() and the plot_RLum.Data.*() functions (#1250, #1300).

  • All the read_*() functions now process and validate the file argument through the same internal helper function. This allows them to support single and multiple files, URLs and directory paths (#1393).

  • The package no longer depends on RcppArmadillo. This has no visible impact to the user other than a small reduction in the package size (#1254).

  • The show method for an RLum.Analysis-class object would fail if the record slot contained NULL elements (fixed in commit f1846c5c).

  • The package has now reached 100% coverage! The test-coverage workflow action has been updated so that any decrease in coverage will be marked as a failure (#548).