NOxTool – NOx Data Analysis Tool
================================

Requirements
------------

Please ensure the following software is installed on your system:

1. Python (version 3.8 or higher recommended)
   Download: https://www.python.org/downloads/
   ⚠️ During installation, make sure to check the option “Add Python to PATH”.

2. Visual Studio Code (VSCode)
   Download: https://code.visualstudio.com/download
   After installation, open the Extensions panel and install the “Python” extension.

Project Setup
-------------

1. Download and extract the ZIP archive
   The ZIP file contains the Python code and a CSV file with NOx data.

2. Open the correct folder
   In VSCode, open the file explorer and click on “Open Folder”.
   ⚠️ Be sure to select the path: NOxTool/NOxTool — not just the outer NOxTool folder.

3. Install required Python packages
   Open the integrated terminal in VSCode (Ctrl + or via Terminal > New Terminal) and run the following command:

   py -m pip install pandas numpy matplotlib scipy scikit-learn


Running the Code
----------------

1. Run the script directly within VSCode.

2. A pop-up window will appear, allowing you to choose whether the analysis should be performed using 1 or 2 variables.

### Variable Selection (Graphical Interface)
When the script is executed, a graphical interface (built with Tkinter) appears. You will be prompted to:
- Select one dependent variable (Y-axis)
- Choose one or two independent variables (X1 and optionally X2)
- Optionally enable grouping by "Combustor Description"

Depending on your selection:
- If "1 Parameter" mode is selected, the tool performs a **power-law regression** with one variable:  
  y = c₀ * x₁^c₁
- If "2 Parameters" mode is selected, it fits the extended model:  
  y = c₀ * x₁^c₁ * x₂^c₂

-----
Notes
-----

- The tool uses Tkinter for graphical input. If errors occur on launch, verify that your Python installation includes tkinter.
- All results (e.g., plots, output files) will be saved in the specified results folder.

## License

This is free software: you can redistribute it and/or modify it  
under the terms of the GNU General Public License as published by  
the Free Software Foundation, License Version 3.

This tool is distributed in the hope that it will be useful,  
but WITHOUT ANY WARRANTY; without even the implied warranty of  
MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  
See the GNU General Public License for more details.

https://www.gnu.org/licenses

