Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Improve readme usage section #53

Closed
dbrakenhoff opened this issue Mar 7, 2022 · 2 comments
Closed

Improve readme usage section #53

dbrakenhoff opened this issue Mar 7, 2022 · 2 comments

Comments

@dbrakenhoff
Copy link
Member

Currently contains too much technical info about Connectors. Should contain something along these lines:

Gettings started.
Define Connector [link to extra info in docs] and PastaStore:

conn = pst.PasConnector("test", "./pastas_db")
pstore = pst.PastaStore(conn.name, conn)

Add head observation time series:

o = pd.read_csv("obs.csv", index_col=[0])
meta = {"x": 100, "y": 200}
pstore.add_oseries(o, "obs1", metadata=meta)
# view oseries metadata with
pstore.oseries

Add stresses time series:

p = pd.read_csv("prec.csv", index_col=[0]
e = pd.read_csv("evap.csv", index_col=[0]
pstore.add_stress(p, "prec1", kind="prec", metadata={"x":110, "y":195}
pstore.add_stress(e, "evap1", kind="evap", metadata={"x":110, "y":195}
# view stresses metadata
pstore.stresses

Create time series models

ml = pstore.create_model("obs1", add_recharge=True)
ml.solve()
pstore.add_model(ml)

Load model from PastaStore:

ml2 = pstore.get_models("obs1")
@dbrakenhoff
Copy link
Member Author

This has been improved on dev, leaving this open until I manage to also implement these improvements in the docs.

@dbrakenhoff
Copy link
Member Author

Closed by #80.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant