## 3 Results and Discussion  
For an NIRS procedure to be understood, the characterization of the spectrum data obtained using the NIRscan Nano prototype is essential. Figure 4 shows the raw and SNV spectra, plus the first Savitzky-Golay derivative spectra of the alfalfa samples included in the calibration procedure. Within the NIR wavelength range of the NIRscan Nano prototype, we can identify some characteristic bands of forages. According to the bibliography, those bands observed at 1166 nm are related to the protein content of the samples [18], and those observed at around 1350 nm are related to the fiber content [19]. Additionally, around 1400 nm, there is a band that can give information about the moisture content because, at that wavelength, OH bond overtone vibrations are observed [20]. In Figures 4 and 5, a rectangle highlights all the cited wavelengths, and the referenced respective parameters. Hence, in Figure 4b, which is an extended area between 1650 and 1700 nm of Figure 4a, we can observe that some of the collected spectra show a noisy signal at the end of the collected spectra. This noisy wavelength range, as shown in Figure 4c, can be minimized after scattering correction (SNV) is applied, along with other mathematical pretreatments, such as derivatives. Figure 4: Spectra of the whole samples: (**a**) raw spectra; (**b**) extended area from 1650 to 1700 nm; (**c**) standard normal variate + first Savitzky–Golay derivative pretreatment. To evaluate the effect of the sample pretreatment on the spectral data set, ground samples were scanned using NIRscan Nano. Figure 5a shows the spectral data set. As can be seen, no differences in the representative bands are observed. Moreover, the extended wavelength range (1650-1700 nm; see Figures 4b and 5b) shows that, after milling the sample pre-treatment, the noisy wavelength range disappears. These data confirm that the spectral quality depends on the sampling procedure (raw or ground). This distorted wavelength range is due to the huge and non-homogeneous particle size of the alfalfa samples. It is worthy of mention that, after the application of mathematical pretreatments, no differences were observed in the collected spectra of the alfalfa samples (see Figures 4c and 5c). As observed in Figures 4 and 5, between 1600 and 1700 nm, the absorbance increases, and the SNR is lower than in other ranges. It is because the intensity measured at the detector is proportional to the number of DMD mirrors positioned to reflect the incident illumination towards it. As the number of pixels changes, the measured intensity is affected as well, resulting in an increase in noise levels. Once the spectra were evaluated, the precision of the subsampling procedure for each scanned sample (raw and ground alfalfa) was evaluated [21]. Five samples were randomly selected from the 57 analysed. The RMS value was calculated for both the intact and ground  
Figure 5: Spectra of the ground samples: (**a**) raw spectra; (**b**) extended area from 1650 to 1700 nm; (**c**) standard normal variate + first Savitzky–Golay derivative pretreatment. samples with the two ranges proposed (901-1700 nm and 901-1600 nm). The results are shown in Table 3.  
Once the values have been calculated, two clear trends can be observed. As expected, the RMS values obtained for the intact samples (raw) are higher than those obtained for the ground ones. These results could be due to heterogeneity in the raw alfalfa. The difference was also significant when the entire spectrum was compared or the last 100 nm was suppressed. Table 3 shows that the RMS values ranging from 900 to 1600 nm are lower than the full range of values. These results highlight the influence of the sampling procedure on the spectrum data precision. After characterizing the spectral signal, the next step was to develop a calibration model. To attempt calibration, it is necessary to build a data matrix including nutritive values (the NDF, MC, and CP) and spectral data.