Spaces:
Running
Running
MilesCranmer
commited on
Commit
•
a300bd3
1
Parent(s):
0430395
Remove example data generator
Browse files- gui/gen_example_data.py +0 -17
gui/gen_example_data.py
DELETED
@@ -1,17 +0,0 @@
|
|
1 |
-
import numpy as np
|
2 |
-
import pandas as pd
|
3 |
-
|
4 |
-
rand_between = lambda a, b, size: np.random.rand(*size) * (b - a) + a
|
5 |
-
|
6 |
-
X = pd.DataFrame(
|
7 |
-
{
|
8 |
-
"T": rand_between(273, 373, (100,)), # Kelvin
|
9 |
-
"P": rand_between(100, 200, (100,)) * 1e3, # Pa
|
10 |
-
"n": rand_between(0, 10, (100,)), # mole
|
11 |
-
}
|
12 |
-
)
|
13 |
-
|
14 |
-
R = 8.3144598 # J/mol/K
|
15 |
-
X["y"] = X["n"] * R * X["T"] / X["P"]
|
16 |
-
|
17 |
-
X.to_csv("data.csv", index=False)
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|