APSIMInitiative / ApsimOnR

7 stars 7 forks source link

auto-generate param_values? #1

Closed frank0434 closed 4 years ago

frank0434 commented 4 years ago

Hi, @hol430

I assume that we still need to provide the param_values as input to have the config_file by a glance of the change_apsimx_param.R fun. https://github.com/hol430/ApsimOnR/blob/480cb842c3d8273c26f806563639ef1c4d991b2c/R/change_apsimx_param.R#L19

wondering if there is a way the APSIMNG can output all the parameters inside the JSON file with their APSIM address ([Lucerne].Grain.Live.N)?

Or the French developers have already established the workflow to do this job but in a separate repo?

thank you

hol430 commented 4 years ago

This is not really possible at the moment and I'm not sure how it would work, as there would be thousands of results. Generally it's up to the user to figure out which property or model they're interested in. If you find the property you're interested in, you can copy its path via the GUI by right-clicking on the model and choosing "copy path to clipboard".

frank0434 commented 4 years ago

cool. Thanks, @hol430

just explore the possibilities that could automate the process. I guess for different user groups will only focus on a particular part of the model. for example, the parameters in one specific crop model and only extract the parameters belongs to it.

It is already a big step from today's chat. will close it for now :)

sbuis commented 4 years ago

Hi Jian and Drew,

I agree that this would be useful, since our models have quite a high number of parameters. We did it for Stics in SticsRFiles package: there is a function for searching parameters names given a part of the name, or, planned but not yet implemented, given a keyword (searched in the parameters definitions). It returns the corresponding parameters names + their bounds and name of the associated file : see https://sticsrpacks.github.io/SticsRFiles/articles/Manipulating_Stics_XML_files.html#searching-parameters-names-from-files).

All the best, Samuel

[Logo-Signature-INRAE]

Samuel Buis samuel.buis@inrae.frmailto:samuel.buis@inrae.fr Ingénieur de Recherche / Research Engineer UMR EMMAH – Environnement Méditerranéen et Modélisation des AgroHydrosystèmes 84914 Avignon 04-32-72-24-26 www.inrae.fr www6.paca.inra.fr/emmahhttps://www6.paca.inra.fr/emmah

De : Jian (AKA Frank) Liu [mailto:notifications@github.com] Envoyé : jeudi 12 mars 2020 03:48 À : hol430/ApsimOnR Cc : Subscribed Objet : Re: [hol430/ApsimOnR] auto-generate param_values? (#1)

cool. Thanks, @hol430https://github.com/hol430

just explore the possibilities that could automate the process. I guess for different user groups will only focus on a particular part of the model. for example, the parameters in one specific crop model and only extract the parameters belongs to it.

It is already a big step from today's chat. will close it for now :)

— You are receiving this because you are subscribed to this thread. Reply to this email directly, view it on GitHubhttps://github.com/hol430/ApsimOnR/issues/1#issuecomment-597979187, or unsubscribehttps://github.com/notifications/unsubscribe-auth/ABSXW6GQYWMLPHADPGMRARDRHBEOPANCNFSM4LGCANRQ.

frank0434 commented 4 years ago

Hi @sbuis

Thanks for sharing the package. will have a close look at the way you implemented the feature. Great package documentation.

thank you :)