Skip to content

Commit af81902

Browse files
Merge pull request #9 from Saltworker/RegressionAnalysis_sciplot
Regression analysis sciplot
2 parents f99ddcc + 75b2c45 commit af81902

File tree

5 files changed

+17
-29
lines changed

5 files changed

+17
-29
lines changed

README.md

Lines changed: 17 additions & 29 deletions
Original file line numberDiff line numberDiff line change
@@ -1,12 +1,11 @@
1-
# Imagine regression analysis using Excel, Geogebra, Graph, etc. except it gets done much faster
1+
# Imagine regression analysis using Excel, Geogebra, Graph, etc. except it gets done much faster (sciplot-edition)
22

3-
![Screenshot](Screenshots/Screenshot_test.jpg)
3+
![Screenshot](Screenshots/Screenshot_1.0-test_sciplot-edition.jpg)
44

55
**NOTE: The program Graph is simply used for testing the results of the regression model & coefficient of determination R^2**
66

7-
## RegressionAnalysis_matplotlibcpp
8-
Regression analysis tool (class regression) utilizing matplotlibcpp.h to graph the results.
9-
Using .txt files as input, the following can be made:
7+
## RegressionAnalysis_sciplot
8+
Regression analysis program utilizing sciplot to plot the results. Using .txt files as input, the following can be made:
109
- Regression model(s) and coefficient(s) of determination R^2
1110
1. Linear
1211
2. Exponential
@@ -22,15 +21,11 @@ Using .txt files as input, the following can be made:
2221
3. Variance, standard deviation, sample standard deviation
2322
- Correlation coefficient r of ONLY linear regression model
2423

25-
**RegressionAnalysis_matplotlibcpp.cpp imports the following files:**
26-
- matplotlibcpp.h
24+
**RegressionAnalysis_sciplot.cpp imports the following files:**
25+
- ...sciplot-master/sciplot/sciplot.h
2726
- [FILENAME].txt
2827

29-
**RegressionAnalysis_matplotlibcpp.exe imports the following files:**
30-
- python310.dll
31-
- [FILENAME].txt
32-
33-
![Screenshot](Screenshots/Screenshot_1.0.jpg)
28+
![Screenshot](Screenshots/Screenshot_1.0-repository_sciplot-edition.jpg)
3429

3530
The format of this [FILENAME].txt can be seen with the available example datasets. Compatible data (in the current state of the program) can be boiled down to the following datapoints:
3631

@@ -50,21 +45,14 @@ The format of this [FILENAME].txt can be seen with the available example dataset
5045
3. .txt file -> CTRL + V
5146

5247
You're welcome
53-
## How to import matplotlibcpp.h
54-
This link should do the trick: https://stackoverflow.com/questions/66507618/running-python-matplotlibcpp-in-visual-studio-2019
48+
## To run regressionAnalysis_sciplot.cpp:
49+
### Install gnuplot
50+
Once this is installed, you'll be able to run the executable attached to the release "1.0 Sciplot-edition"
51+
52+
https://sourceforge.net/projects/gnuplot/
53+
54+
**NOTE: Make sure to set {...\gnuplot\bin} as an environment variable**
55+
### Install sciplot
56+
https://github.com/sciplot/sciplot
5557

56-
To sum up the proces of importing matplotlibcpp, here is a checklist:
57-
1. Open command prompt. Check if python is installed (python versions 3.7 - 3.9 are recommended. Newer versions of python will cause unwanted errors) by entering the first of the following commands:
58-
- python --version
59-
- python -m pip install matplotlib
60-
- python -m pip install numpy
61-
2. Create project (I used visual studio 2022)
62-
3. Download matplotlibcpp.h: https://github.com/lava/matplotlib-cpp/blob/60dcd64c8fd4766e5426f57decfb765422a1d3fe/matplotlibcpp.h#L303
63-
- SANITY CHECK: Make sure to get rid of (ll. 351-356) inside of matplotlibcpp.h
64-
4. Move matplotlibcpp.h to project repository. Alternatively include header file via solutions explorer [SHIFT+ALT+L]
65-
5. From the used python repository, include the following under "include Directories":
66-
- ...\Python37\include
67-
- ...Python37\Lib\site-packages\numpy\core\include
68-
6. From the used python repository, include the following under "Library Directories":
69-
- ...\Python37\libs
70-
7. Don't forget to set Solution Configurations to RELEASE
58+
Include the downloaded "sciplot-master" following under "include Directories": {...\sciplot-master}
52.4 KB
Loading
278 KB
Loading

Screenshots/Screenshot_1.0.jpg

-75.7 KB
Binary file not shown.

Screenshots/Screenshot_test.jpg

-355 KB
Binary file not shown.

0 commit comments

Comments
 (0)