proximetricsR 0.7.1 "Valinhos"
===============
* Feat: new dataset `proxiscoutCannabis`, containing absorbance spectra of 192 cannabis samples measured with three ProxiScout devices at the 257 standard ProxiScout wavenumbers, together with eleven cannabinoid reference variables (`CBDA`, `CBG`, `CBD`, `CBN`, `THC`, `THCA`, `CBC`, `CBGA`, `CBD_total`, `THC_total` and `CBGt`). The set includes one deliberate outlier and a `deviceId` column usable as `validation_group`.
* Deprecated: the dataset `NIRcannabis` was renamed to `proximateCannabis`, for consistency with the new `proxiscoutCannabis` dataset. The old name still works but is deprecated and will be removed in a future release.
* Breaking: the dataset `NIRcannabis` was renamed to `proximateCannabis`, for consistency with the new `proxiscoutCannabis` dataset. The old name is kept as a deprecated copy and will be removed in a future release.
* Docs: `proximateCannabis` and `proxiscoutCannabis` cross-reference each other, noting that they share neither samples nor reference values.
* Feat: validation results now include the Mahalanobis (GH) distance, computed from scaled PLS scores, and the spectral (X-space) residual for each sample. Both are returned by `calibrate_models()` and `validate_prediction()` and are available for downstream analysis.
* Feat: `plot.spectral_model()` gained a `validation_group` argument to colour validation samples by group, for example by instrument.
* Feat: new "Leverage vs. Spectral Residual" validation plot, showing each sample's leverage and spectral residual relative to their control limits (dashed line at 1), with grouped colouring.
* Feat: `predict.spectral_model()` returns per-component control limits for the leverage (new-observation Mahalanobis limit) and spectral residual Q (calibration quantile), configurable via `control_limit_conf` (default 0.99) and carried through `validate_prediction()`.
* Misc: group argument checking for `sample_group` and `validation_group` refactored into a single internal helper.
* Fix: `predict.spectral_model()` no longer misaligns `newdata` with `prep_wav_trim(trim_constant_edges = TRUE)`; the trimmed band is resolved at calibration time and reapplied deterministically.
* Fix: the `nwp` fit method left `projection_m` out of its slope correction, so scores of new samples (and therefore their leverage and spectral residual) were wrong; predictions were unaffected.
* Feat: `proxiscout_write_data()` also writes a `<prefix>_metadata.csv` with the sample names and any leftover columns.
* Fix: `proxiscout_write_data()` renames the correct `SNR`/`SRN` column to `deviceId` and honours integer `spc`.
* Fix: `proxiscout_write_data()` now writes consistent `sampleName`/`deviceId` headers across all files (the spectra file previously used `Sample Name`/`Device Id`).
* Tests: added unit tests for `proxiscout_write_data()`.
* Fix: `proxiscout_read_data()` now treats `""`, `"-"` and `"NA"` as missing values when reading CSV and XLSX files, so numeric columns using these placeholders are read as numeric.
* Fix: `extract_property_names()` no longer returns the internal `.repetition_group` column as a property for `proxiscout_data`.
* Tests: added unit tests for `extract_property_names()` and the missing-value handling in `proxiscout_read_data()`.
* Docs: documented the new arguments, validation statistics and plot, including in `model_plot_template.qmd`.

proximetricsR 0.7.0 "Matterhorn2"
===============
* Feat: `proximate_read_data()` now automatically detects and handles UTF-8 vs Windows-1252/ANSI encoded TSV files, ensuring correct decoding of special characters in metadata regardless of locale.
* Feat: improved merging logic in `proxiscout_read_data()` for spectral and reference files, with more robust column matching and documented support for repetition groups via the `.repetition_group` column.
* Feat: `plot.spectral_model()` gained a new `sample_group` argument to colour plots by sample group. `scales` added to Imports.
* Feat: added and exported `proxiscout_write_model_info()`, which writes model metadata to JSON.
* Fix: `calibrate_models()` no longer reconstructs formulas from strings, using the original list instead, improving accuracy and robustness.
* Misc: updated package logo.


proximetricsR 0.6.5
===============

* Docs: fixed unescaped "<" characters in mathematical notation within `calibration_control.Rd`, which caused HTML validation errors on CRAN.

* Tests: added unit tests for `proxiscout_write_model()` to guarantee the integrity of ProxiScout model serialisation across preprocessing recipes.

proximetricsR 0.6.4
===============
* Hello world!