In this paper we propose an "ad-hoc" construction of the Likelihood Function, in order to develop a data analysis procedure, to be applied in atomic and nuclear spectral analysis.The classical Likelihood Function was modified taking into account the underlying statistics of the phenomena studied, by the inspection of the residues of the fitting, which should behave with specific statistical properties. This new formulation was analytically developed, but the sought parameter should be evaluated numerically, since it cannot be obtained as a function of each one of the independent variables. For this simple numerical evaluation, along with the acquired data, we also should process many sets of external data, with specific properties -This new data should be uncorrelated with the acquired signal.The developed statistical method was evaluated using computer simulated spectra. The numerical estimations of the calculated parameter applying this method, indicate an improvement over accuracy and precision, being one order of magnitude better than those produced by least squares approaches.We still have to evaluate the improvement produced by this method over Detection and Quantitation Limits, in TXRF spectral analysis.