I am trying to add vegetation zones to the SNOW-17 model in goldsim. Currently, zones are based off elevation which you input into a vector. I want to create a secondary zone delimiter based off vegetation that would effect the value of other factors such as melt rates. I have two main questions:
1. I currently have two vectors. One vector has zone numbers and elevation. The other has zone numbers and vegetation assignments. Is this the best way to do it? I would know zone 1 has x elevation from the first vector and y vegetation from the second vector. Or would this make more sense to have them in the same table? I believe vectors can only have one column. So should I do this in a look-up table instead? The lookup tables aren't happy about my column names if I do that because it says they aren't numbers.
2. How to identify which melt factor to use based off the zone's vegetation. I was trying to use a selector for this but GoldSim is not happy about that. Is this the proper tool to be using? Essentially I want an if elif statement that would say:
if vegetation = 10:
melt factor is x
elif vegetation = 20:
melt factory is y
else:
melt factor is z
This is my first attempt but I am getting the error "Incompatible data types. The order of the expression result is Scalar, while the input requires Vector[VegZones]." I appologize if the answer is obvious here. I'm still new to goldsim.







Comments
4 comments