Menu Close

Error “The state class could not be located in ‘To Primary Stratum’”

Syncrosim Forums ST-Sim & State-and-Transition Simulation Models Error “The state class could not be located in ‘To Primary Stratum'”

Viewing 4 posts - 1 through 4 (of 4 total)
  • Author
    Posts
  • #22718
    Katrina SzeteyKatrina Szetey
    Participant

    Hi, I’m trying to set up transition pathways and after working fine for 23 transition pathways, I am suddenly getting the error “The state class <class> could not be located in ‘To Primary Stratum'” on the 24th pathway. I’m wondering if it’s a bug (the number 24 always gives me pause), as I’m not even using the ‘To Primary Stratum’ column in my pathways, only ‘Class’ and ‘To Class’. I’m using V 2.4.44.

    #22719
    Katrina SzeteyKatrina Szetey
    Participant

    Sorry, just to clarify, that’s the Syncrosim version, and stsim package version 3.3.14.

    #22723
    katie-birchardkatie-birchard
    Keymaster

    Hi Katrina,

    How have you set up the data for the Transition Pathways > States and Transition Pathways > Transitions datasheets? (If you are working in R or python rather than the User Interface, the internal names for these datasheets are “stsim_DeterministicTransition” and “stsim_Transition”)

    This error can occur if the pathway is going to a state class that has not been defined in the Transition Pathways > States (“stsim_DeterministicTransition”) datasheet for the stratum you are working on. Even if you are not using the “To Primary Stratum” column, you can still get this error as SyncroSim sets the “To Primary Stratum” value to be the same as the “From Primary Stratum” value by default.

    Are you using R or python to build your models? In the User Interface, if you try to add state classes to the Transition Pathways > Transitions (“stsim_Transition”) datasheet that don’t have valid stratum values in the Transition Pathways > States (“stsim_DeterministicTransition”) datasheet, you will get an error while you are inputting your data. However, you don’t get the same validation if you are building your models using R or python.

    Cheers,
    Katie

    #23214
    Katrina SzeteyKatrina Szetey
    Participant

    Sorry, it took me a while to get back to this. I have checked and what you suggested was the problem. I think I must have been having an off day! Thanks for your help 🙂

Viewing 4 posts - 1 through 4 (of 4 total)
  • You must be logged in to reply to this topic.