RDRS SpectraLib

v26.4.5b
⊕ DROP SPECTROSCOPY FILES HERE
Drop CSV / TXT files here
or click to browse
Spectra 0 loaded
    Display Settings
    Width:
    Labels:
    Interactive Tools
    Δ:
    Preprocessing
    Analysis
    X: 0.00 | Y: 0.00 View: Auto
    You must be logged in to use this feature.
    RDRS SpectraLib Documentation

    About RDRS SpectraLib

    A comprehensive, instrument-grade web application designed for the visualization, advanced processing, and high-speed mathematical matching of Raman and infrared spectra. Built to process proprietary laboratory data alongside massive open-source reference libraries.

    Data Privacy Guarantee: All spectrum parsing and processing happens completely locally in your browser. Your raw data files and spectra are never uploaded, saved, or collected by RDRS SpectraLib server.

    Scientific Use & Citations

    RDRS SpectraLib is provided as a free tool for the academic and scientific community. If you use RDRS SpectraLib in your scientific work, publications, or presentations, please reference the software as:

    Apopei A. I. 2026. RDRS SpectraLib - integrated spectral library & analysis web platform, version v26.4.5b, https://rdrs.uaic.ro
    • Please ensure you insert the current version number (found in the top right header).
    • You may leave out the part in quotation marks.
    • (And please, try to get the spelling right!)

    Developed by Andrei Ionuț Apopei, PhD

    andrei.apopei@uaic.ro geology.uaic.ro/andrei.apopei linkedin.com/in/aiapopei

    Basic Workflow (Multiple Spectra)

    RDRS SpectraLib is designed to handle dozens of spectra simultaneously. When you open any processing tool (like Smooth or Baseline), you will see a list of all your loaded spectra.

    1. Check the boxes next to the spectra you want to process. (Visible spectra in the chart are checked by default).
    2. Select your settings and click Apply.
    3. By default, RDRS SpectraLib keeps your original data and creates a brand new, processed copy with a tag (like [SG] or [Cut]) added to the name.

    Reference Database

    Load pure, verified reference spectra directly into your chart for visual comparison.

    How to use: Type a mineral name (e.g., "Quartz") into the Global Search, or use the dropdowns to browse by Technique and Class. Check the boxes of the minerals you want, and click Add to Chart. Hovering over a result will show a live preview overlay.

    Data Sources & Citations

    • RRUFF Project: A comprehensive collection of 14,000+ Raman and infrared spectra of minerals, provided by the University of Arizona. When publishing data analyzed using these reference matches, please cite:
      Lafuente, B., Downs, R. T., Yang, H., & Stone, N. (2015). The power of databases: the RRUFF project. Highlights in Mineralogical Crystallography, T Armbruster and R M Danisi, Eds., Berlin, Germany, W. De Gruyter, 1–30.
    • Raman Open Database (ROD): An interconnected open-access resource for Raman spectroscopy and X-ray diffraction material identification. Please cite:
      El Mendili, Y., Vaitkus, A., Merkys, A., Gražulis, S., Chateigner, D., Mathevet, F., ... & Le Guen, M. (2019). Raman Open Database: first interconnected Raman–X-ray diffraction open-access resource for material identification. Applied Crystallography, 52(3), 618-625.
    • RDRS SpectraLib Database: Our proprietary internal database. Currently under active development (spectra organization and processing phase).
      Buzgar N., Apopei A. I., & Buzatu A. (2009). Romanian Database of Raman Spectroscopy (https://rdrs.uaic.ro).

    Match Spectrum to Database (logged users)

    Identify an unknown sample by comparing it against our 11,400+ reference library using traditional mathematical algorithms or advanced Artificial Intelligence.

    Available Algorithms:

    • Machine Learning: Features models trained specifically on pure Raman, Infrared (FT-IR), and X-Ray Diffraction (XRD) datasets. Achieves high validation accuracy by intelligently ignoring noise and background humps. Best for identifying the single dominant phase in a sample.
    • AI: Multi-Phase Mixture (Experimental): A multi-label neural network designed to untangle and identify multiple overlapping minerals in a single mixed rock. (Available for standard Raman and XRD). Use the Sensitivity Slider to adjust detection limits: lower it to find hidden trace minerals, or raise it to prevent false positives.
    • 1st Derivative: The traditional gold-standard. Mathematically strips away sloped baselines to match pure peak inflection points.
    • Pearson / Cosine: General curve shape and intensity correlation matchers.

    How to use:

    1. Select exactly one unknown spectrum from the list.
    2. Select the correct Database Category to route your data to the appropriate AI brain. (Ensure your X-axis units match the required format for that technique!)
    3. Select your algorithm. (If using the Multi-Phase Mixture, adjust your Sensitivity threshold).
    4. Click Find Best Matches.

    Pro Tip for Mixtures: The Multi-Phase AI is highly sensitive to background fluorescence and amorphous humps. Always run an Auto Baseline (ALS) on your sample before matching to ensure maximum accuracy!

    Note: Results are paginated. You can load up to the top 50 closest matches by clicking "Show Next 10 Results" at the bottom of the list.

    Advanced Plot Configuration

    RDRS SpectraLib gives you deep, publication-level control over how your data is rendered on the screen. These settings are cached in your browser so your preferred lab aesthetic loads automatically every time.

    • Global - Rendering Engine: SVG is the default engine (crisp lines, perfect for PDF exports). WebGL offloads rendering to your GPU for 60fps panning when analyzing massive datasets (50+ spectra), though filled areas may show minor artifacts.
    • Global - Mirror Axes: Draws a solid bounding box around the top and right sides of the chart, replicating your tick styles. This is the standard aesthetic for most scientific journals.
    • Axis Scales (Linear vs Logarithmic): Logarithmic scales are incredibly useful when a massive fluorescence hump dwarfs a tiny Raman signal. Note: Log scales require strictly positive data.
    • Ticks & Grids: Independently toggle gridlines, axis lines, and minor ticks for the X and Y axes. You can also change the direction of major ticks (Inside, Outside, Cross, or Hidden) to match specific publication formatting rules.

    Pro-Tip: If you ever accidentally hide your axes or mess up your chart layout, click File > Reset Settings at the top of the screen to instantly restore the default factory view!

    Display Settings

    Visual toggles to customize your workspace appearance. These do not mathematically alter raw data arrays.

    • Flip X: Reverses the X-axis direction.
    • Legend: Cycles the chart legend between Outside, Floating, and Hidden.
    • Grid: Toggles background layout gridlines.
    • Reset View: Instantly restores default zoom, offsets, tools, and display states.
    • Lines: Cycles the rendering engine between continuous Lines, independent Points, or Both. Use Width to adjust thickness.
    • Labels: Adjusts the font size of detected peak annotations.
    • Fill: Shades the area under the curve. Reveals a dynamic UV-Vis rainbow gradient if your X-axis is set to [nm].
    • Reorder: Enables drag-and-drop functionality on the left sidebar to perfectly arrange your stack order. Click the icon next to a spectrum to instantly rename it.

    Interactive Tools

    Tools that modify the chart's physical layout and active tracking.

    • Stack: Vertically separates overlapping spectra by a standard offset (Δ).
    • Auto-Norm: Temporarily min-max scales all spectra to a 0-1 range for visual comparison without changing the underlying raw detector counts.
    • Drag Y: Activate this to physically click and drag spectra vertically across the chart for rapid visual alignment.
    • Cursor: Click anywhere on the chart to drop vertical tracking lines. Useful for identifying peak boundaries before integration.
    • Heatmap: Instantly transforms all visible spectra into a dense 2D color contour plot. Perfect for visualizing temperature series or spatial mapping.
    • Freehand Edit: Danger! Manually "paint" over massive artifacts to force the data down to zero. Note: This permanently alters the raw data points.
    • Manual Baseline: Click to physically drop and draw a custom baseline under your peaks. Turn on the Snap magnet to lock your clicks directly to the true data line.

    Cut Range & Scale Y

    • Cut Range: Deletes all data outside of the X-bounds you provide. Excellent for removing noisy detector edges.
    • Scale: Multiplies the intensity by a specific factor. Note: You can also visually scale spectra without altering the raw data by changing the ×Scale box in the left sidebar next to the spectrum name!

    Zap Peak (Excise)

    Removes bad data points (like stubborn artifacts or saturated solvent peaks) and heals the gap with a clean, interpolated line.

    How to use: Input the exact X-axis center of the bad peak, and how wide the cut should be. RDRS SpectraLib will delete the data in that window and draw a straight line connecting the two broken ends.

    Cosmic Ray Removal (Despiking)

    Automatically detects and removes artificially sharp spikes caused by high-energy particles hitting the camera sensor.

    • Derivative (Gradient) algorithm: The industry standard. Identifies cosmic rays by hunting for near-vertical instantaneous slopes (which true Raman peaks do not have). Excellent for preserving sharp diamond or silicon peaks.
    • Z-Score (Median) algorithm: Best for broader artifacts or saturated pixels.

    Tip: Keep Live Preview checked! The red dashed line will show you exactly what the cleaned spectrum looks like before you apply it.

    Smoothing & Normalization

    • Region-Specific Smooth: You can now provide an X Start and X End to smooth only a noisy section of your spectrum (e.g., a noisy baseline at high wavenumbers) while perfectly preserving sharp, pristine peaks in the rest of the array!
    • Savitzky-Golay is the gold standard for spectroscopy as it preserves sharp peak heights. Percentile Filter (Median) is excellent for removing sharp cosmic ray spikes.
    • Normalize: Scales the Y-axis so all spectra fit within a specific range (e.g., 0 to 1), making it easier to compare the shapes of weak and strong signals.

    Automatic Baseline Correction

    Removes thermal noise, fluorescence, or sloped backgrounds from your data.

    • Auto Baseline: Uses advanced algorithms to mathematically guess the background. ALS (Asymmetric) is the gold standard for massive fluorescent humps. Adaptive (SNIP) is also excellent for Raman, while Scattering (Poly) handles broad, wavy backgrounds.

    Shift X-Axis

    Corrects instrumental calibration errors by manually shifting the data horizontally.

    How to use: Enter a positive number to shift the peaks to the right (higher wavenumbers), or a negative number to shift them to the left. The Y-intensities remain completely unchanged.

    Unit & Axis Conversions

    A unified tool to mathematically transform your data arrays or fix imported metadata.

    • Vibrational Math: Converts physical X units for optical spectroscopy (e.g., nm ↔ cm⁻¹, eV, THz). Note: Formulas like nm to eV mathematically reverse the array, which RDRS SpectraLib handles and re-sorts automatically.
    • Diffraction Math (XRD): Uses Bragg's Law (nλ = 2d sinθ) to convert between 2-Theta angles and physical d-spacing.
    • XRD Target Conversion: Crucial for AI Matching! The RDRS AI models are trained exclusively on Copper (Cu Kα1) radiation. If your diffractometer used a different anode (like Cobalt or Molybdenum), you must use this tool to mathematically convert your 2-Theta angles to the Copper standard before running a match.
    • Y-Axis Math: Converts intensity scales (e.g., Transmittance % ↔ Absorbance).
    • Rename Labels: Overwrites the global axis titles for your PDF reports without altering the underlying raw data points.

    Batch Processing Pipeline (Macros)

    The ultimate power-user tool. Apply an entire sequence of mathematical operations to dozens of spectra with a single click.

    How to use: Check the boxes for the operations you want to apply (Cut, Smooth, Baseline, Normalize), adjust the specific parameters, and click Run Pipeline. RDRS SpectraLib will sequentially chain the math together in the background.

    Find Peaks

    Automatically detect and label peaks (maxima) or valleys (minima) based on height thresholds.

    When peaks are found, RDRS SpectraLib automatically calculates the FWHM (Full Width at Half Maximum) for crystallographic analysis. The results are automatically logged to the Console and exported in your PDF reports.

    Integrate Peak Area

    Calculates the area under a curve, which is proportional to chemical concentration.

    How to use: Click the ✛ Cursor tool in the left panel to find the X-axis start and end points of your peak. Enter those numbers here. The Console Log will open and display the Total Area (down to zero) and the Net Area (above the local background).

    Colorimetric Analysis (CIE 1931)

    Extracts the true mathematical color (Hex code and x,y coordinates) from an emission or photoluminescence spectrum.

    How to use: Your X-axis must be set to Wavelength [nm]. Input the X bounds to isolate the material's emission peak (carefully excluding the excitation laser/LED). The application integrates the area using standard CIE 1931 Color Matching Functions and outputs the precise color swatch directly to the Console.

    Peak Curve Fitting (Deconvolution)

    Resolves heavily overlapping peak clusters into individual mathematical components using Levenberg-Marquardt optimization. You can now model true physical and instrumental states by selecting specific Profile Shapes.

    How to use:

    1. (Highly Recommended) Click Visually Pick Centers. The modal will become transparent. Click directly on the chart to drop vertical markers where you suspect hidden peak shoulders are located. (Right-click to undo, or use the trash icon to start over).
    2. Auto-Bounding: As you drop centers, RDRS SpectraLib will automatically calculate the optimal X Start and X End bounds to isolate the cluster for you! (You can still type these manually if needed).
    3. Click Finish Picking.
    4. Select your Profile Shape. (See the guide below).
    5. If you choose to skip visual picking, manually enter your X-bounds and select the Number of Peaks (up to 10) to force the solver to blindly guess.
    6. Click Run Optimization.

    Which Profile Shape should I choose?

    • Gaussian: Best for modeling the blur caused strictly by the instrument/spectrometer (slits, gratings).
    • Lorentzian: Best for modeling the true physical nature of the sample, such as vibrational lifetime decay (Raman) or crystallite size/strain (XRD).
    • Pseudo-Voigt (Mixed): The absolute gold standard for real-world data. It perfectly blends Gaussian (instrument) and Lorentzian (sample) profiles together.

    Why pick centers visually? Blindly guessing peak locations often causes the math to fail on asymmetric data. By clicking the exact X-coordinates, you give the algorithm a perfect starting line, guaranteeing sub-second convergence for complex overlaps.

    Advanced Solver Parameters: If your data is extremely noisy and triggers an 'Optimization failed to converge' error, expand the Advanced Parameters drawer. Increase the Max Iterations (e.g., 20000) or lower the Tolerance (e.g., 1e-6) to force the math to solve it.

    Derivative Spectroscopy

    Calculates the 1st or 2nd derivative to identify hidden shoulders or overlapping bands. Because derivatives amplify signal noise exponentially, always apply a Savitzky-Golay Smooth prior to using this tool.

    Spectral Stripping (Subtract)

    Used to mathematically remove a pure reference phase from a mixed sample spectrum.

    How to use: Select your mixed sample (Minuend) and the pure database reference (Subtrahend). Slowly drag the multiplier slider. Watch the chart update live until the reference peaks visually disappear from your mixed sample.

    Merge Spectra (Stitch)

    Combines multiple spectral segments (e.g., from a dual-grating spectrometer) into one continuous trace.

    How to use: Select the spectra you want to weave together. RDRS SpectraLib will automatically sort them by X-axis, interpolate any empty gaps, and average any overlapping regions to create a single, seamless line.

    Add & Divide Spectra

    Perform direct mathematical operations between multiple target spectra and a single reference spectrum.

    • + Add Spectra: Adds the Y-values of a reference spectrum to your selected targets.
    • ÷ Divide Spectra: Divides your target spectra by a reference spectrum. Essential for calculating Transmission/Reflectance ratios.

    Auto-Alignment Magic: RDRS SpectraLib will automatically interpolate the reference data to perfectly align with each target's X-axis before calculating the results.

    Spectrum Averaging & Variance

    Calculates the Mean (average) of multiple spectra. Highly recommended for heterogeneous samples where multiple acquisitions were taken. If you check Draw ±1 Std. Dev., it will draw a semi-transparent shaded area behind the main line representing the sample variance!

    Principal Component Analysis (PCA)

    PCA is an advanced unsupervised Machine Learning technique that reduces the dimensionality of complex spectra. It looks for the greatest sources of variance (differences) across your entire dataset.

    How to use: Select at least 3 spectra (ideally dozens) and click Compute. The server will standard-scale your data and return a 2D Scatter Plot. Spectra that are chemically identical will cluster together in tight groups. Outliers (like a spectrum ruined by a cosmic ray or a completely different mineral) will plot far away from the main clusters.

    Pro-Tip: Click any dot on the PCA Scatter Plot to instantly isolate and view that specific spectrum in the main workspace!

    Linear Combination Fitting (LCF)

    Quantifies the percentage composition of a mixed sample using Non-Negative Least Squares (NNLS).

    How to use: Baseline correct your mixed sample. Load the pure reference spectra from the database. Open the LCF tool, select the mixture as the Target, check the references, and calculate. The algorithm builds a synthetic "Fit" curve and logs the exact mathematical percentages to the Console.

    Evaluate Quality (SNR)

    Automatically calculates the Signal-to-Noise Ratio (SNR) for all visible spectra to help you quickly identify pristine data and flag noisy, unusable acquisitions.

    How to use:

    1. Leave only the spectra you want to evaluate visible on the chart.
    2. Click the tool to open the configuration modal.
    3. Set your custom thresholds for what your specific lab considers Good vs Poor quality.
    4. Click Evaluate SNR.

    Results will appear as colored badges directly in the left sidebar next to each spectrum's name.

    UV-VIS Acquisition (Live Hardware)

    Connect a USB Camera or an OBS Virtual Camera (for SharpCap integration) to capture live photons from a diffraction grating.

    • Extract Y & Slit Height: Define the exact horizontal slice (Region of Interest) of the video feed to digitize.
    • Start / End X: Crop the dead space around your spectrum. This dramatically boosts performance for high-resolution 4K sensors.
    • Live Smooth (IIR): An Infinite Impulse Response filter. Lower this slider to integrate light over time, reducing sensor noise without losing responsiveness.
    • Lock Y-Axis: Prevents the chart from violently "bouncing" or auto-scaling when you turn a flashlight on or off.

    How to Calibrate to Nanometers:

    1. Turn off the Cursor tool, then click and drag the chart to zoom into your first known peak (e.g., the blue 436nm line from a CFL lamp).
    2. Turn the Cursor tool ON, and click the peak to drop a tracking line.
    3. Click Set P1 in the calibration panel.
    4. Turn the Cursor tool OFF, zoom over to your second known peak (e.g., the green 546nm CFL line), drop a cursor, and click Set P2.
    5. Click Apply Math. Your X-axis will instantly convert to nanometers, and a UV-Vis rainbow will appear behind the trace!
    Knowledge Base
    Processing…