iode.Equations
- class iode.Equations
IODE Equations database.
- Parameters:
- filepath: str, optional
file containing the IODE equations to load.
- Returns:
- Equations
Examples
>>> from iode import equations, SAMPLE_DATA_DIR >>> equations.load(f"{SAMPLE_DATA_DIR}/fun.eqs") >>> len(equations) 274 >>> equations Workspace: Equations nb equations: 274 filename: ...\tests\data\fun.eqs name lec method sample block fstat r2adj dw loglik date ACAF (ACAF/VAF[-1]) :=acaf1+acaf2*GOSF[-1]+ acaf4*(TIME=1995) LSQ 1980Y1:1996Y1 ACAF 32.2732 0.7963 2.3293 83.8075 12-06-1998 ACAG ACAG := ACAG[-1]+r VBBP[-1]+(0.006*VBBP[-1]*(TIME=2001)-0.008*(TIME=2008)) LSQ : ACAG 0.0000 0.0000 0.0000 0.0000 AOUC AOUC:=((WCRH/QL)/(WCRH/QL)[1990Y1])*(VAFF/(VM+VAFF))[-1]+PM*(VM/(VAFF+VM))[-1] LSQ : AOUC 0.0000 0.0000 0.0000 0.0000 BENEF d BENEF :=d(VBNP-(IT+ITCEE)+SUB-DPUU-(WCF+SSFFIC+WDOM+WBG+ YN)-(GOSH-DPUH+IDH)-DTF-RIDGG+YIDG) LSQ : BENEF 0.0000 0.0000 0.0000 0.0000 BQY BQY:=(YK+YN)/PBBP LSQ : BQY 0.0000 0.0000 0.0000 0.0000 ... ... ... ... ... ... ... ... ... ... YSSF dln YSSF:=dln WBF_ LSQ : YSSF 0.0000 0.0000 0.0000 0.0000 YSSG YSSG := SSF+SSH-(YSSF+COTRES) LSQ : YSSG 0.0000 0.0000 0.0000 0.0000 ZF grt ZF :=grt PC+ZX-0.05*grt PME LSQ : ZF 0.0000 0.0000 0.0000 0.0000 ZJ grt ZJ :=grt PC +ZX-0.05*grt PME LSQ : ZJ 0.0000 0.0000 0.0000 0.0000 ZZF_ ZZF_ := ZZF_[-1] LSQ : ZZF_ 0.0000 0.0000 0.0000 0.0000
- Attributes:
- filename: str
- description: str
Methods
clear(self)Delete all objects from the current database.
copy(self)Create a copy of an IODE database.
copy_from(self, input_files[, objects_names])Copy (a subset of) objects from the input file(s) 'input_files' into the current database.
estimate(self[, from_period, to_period, ...])Estimate an equation or a block of equations.
from_frame(self, df)Copy the pandas DataFrame df into the IODE Equations database.
from_series(self, s)Copy the pandas Series s into the IODE Equations database.
get_names(self[, pattern])Returns the list of objects names given a pattern.
is_copy_subset(self)Whether or not the present object represents of a subset of a global IODE database and if the IODE objects of the subset represent deep copies of the IODE objects from the global IODE database.
is_subset(self)Whether or not the present object represents a subset of a global IODE database.
load(self, filepath)Load objects stored in file 'filepath' into the current database.
merge(self, other[, overwrite])merge_from(self, input_file)Merge all objects stored in the input file 'input_file' into the current database.
remove(self, names)Delete the object(s) named 'names' from the current database.
rename(self, old_name, new_name)Rename an object of the database.
save(self, filepath)Save objects of the current database into the file 'filepath'.
search(self, pattern[, word, ...])Return a list of all objects from the current database having a specific pattern in their names or LEC expression, comment...
to_frame(self)Create a pandas DataFrame from the current Equations database.
- __init__(*args, **kwargs)
Methods
__init__(*args, **kwargs)clear(self)Delete all objects from the current database.
copy(self)Create a copy of an IODE database.
copy_from(self, input_files[, objects_names])Copy (a subset of) objects from the input file(s) 'input_files' into the current database.
estimate(self[, from_period, to_period, ...])Estimate an equation or a block of equations.
from_frame(self, df)Copy the pandas DataFrame df into the IODE Equations database.
from_series(self, s)Copy the pandas Series s into the IODE Equations database.
get_names(self[, pattern])Returns the list of objects names given a pattern.
is_copy_subset(self)Whether or not the present object represents of a subset of a global IODE database and if the IODE objects of the subset represent deep copies of the IODE objects from the global IODE database.
is_subset(self)Whether or not the present object represents a subset of a global IODE database.
load(self, filepath)Load objects stored in file 'filepath' into the current database.
merge(self, other[, overwrite])merge_from(self, input_file)Merge all objects stored in the input file 'input_file' into the current database.
remove(self, names)Delete the object(s) named 'names' from the current database.
rename(self, old_name, new_name)Rename an object of the database.
save(self, filepath)Save objects of the current database into the file 'filepath'.
search(self, pattern[, word, ...])Return a list of all objects from the current database having a specific pattern in their names or LEC expression, comment...
to_frame(self)Create a pandas DataFrame from the current Equations database.
Attributes
descriptiondescription: str
df: DataFrame
filenamefilename: str
namesnames: List[str]