A cohort model issue

A place for Ventity software questions & answers
moudi
Senior Member
Posts: 59
Joined: Thu Nov 18, 2010 9:18 am

A cohort model issue

Postby moudi » Fri May 12, 2017 6:14 am

Hi

I would like to implement the following: At the onset of a coronary event a new entity is created (CHD Cohort). This cohort should receive the new cases with CHD (incidence rate CHD) as the initial value. My idea is that these cohorts are created continuously, but are nonzero only if they are populated with this incidence rate CHD. Deaths depend a) on age and a mortality rate depending on age and b) on a Standardized Mortality Ratio, depending on the time since the event.
In the model attached here this seems to work. However, in addition I would like to calculate the fraction of the population in this cohort which survives. For this reason I should have a variable which retains the initial value of this cohort. This I don't manage.

Note, that the model presented here is very basic. I just wanted to understand (and control) the mechanism. For this reason I put many issues in the model entity.

Thanks and regards

Model SMR3 contains the questionable variable and does not work, SMR4 is running.
CohortPop2 test SMR3.zip
(12.33 KiB) Downloaded 16 times
CohortPop2 test SMR4.zip
(12.03 KiB) Downloaded 12 times

tomfid
Administrator
Posts: 1954
Joined: Wed May 24, 2006 4:54 am
Location: Montana, USA
Contact:

Re: A cohort model issue

Postby tomfid » Fri May 12, 2017 7:46 pm

How about putting the initial value into a stock ("original population" or similar) that persists?
/*
Advice to posters (it really helps us to help you)
viewtopic.php?f=2&t=4391

Blog: http://blog.metasd.com
Model library: http://models.metasd.com
Bookmarks: http://delicious.com/tomfid/SystemDynamics

*/

moudi
Senior Member
Posts: 59
Joined: Thu Nov 18, 2010 9:18 am

Re: A cohort model issue

Postby moudi » Mon May 15, 2017 6:18 am

Right. It works like this. Thanks for the hint.

moudi
Senior Member
Posts: 59
Joined: Thu Nov 18, 2010 9:18 am

Re: A cohort model issue

Postby moudi » Fri Jun 02, 2017 3:42 am

Hi

I would like to model a problem where in a cohort entity a second cohort creation action is defined. These "subcohorts" (here called "Cohort with CHD"), should receive the incidence of CHD as initial value, and retain the age of the original cohorts. This works so far. For the sake of simplicity I put the first create action in the model entity. However, the problem arises, when I want to use the age of the original cohorts in the "cohorts with CHD" to calculate the death rates. Here Ventity does not know, which information to use. Presumably a reference problem. Please, find attached this model (Test subcohort4).
Test subcohort4.zip
(11.9 KiB) Downloaded 10 times


Thanks for any suggestion.

tomfid
Administrator
Posts: 1954
Joined: Wed May 24, 2006 4:54 am
Location: Montana, USA
Contact:

Re: A cohort model issue

Postby tomfid » Sat Jun 03, 2017 1:34 pm

If I understand this, you basically want a way for the CHD Cohort to determine its age, which should match that of its corresponding Cohort.

I think the best way to do that is to populate the CHD Cohort's Cohort attribute with the name of the parent. That is, in the create action, initialize Cohort to Parent.CohortID. Then you can use that reference attribute to get the parent's age. You don't need any local age calculations in the CHD Cohort at all, unless you also need to know its age since creation, distinct from the parent.
/*
Advice to posters (it really helps us to help you)
viewtopic.php?f=2&t=4391

Blog: http://blog.metasd.com
Model library: http://models.metasd.com
Bookmarks: http://delicious.com/tomfid/SystemDynamics

*/

moudi
Senior Member
Posts: 59
Joined: Thu Nov 18, 2010 9:18 am

Re: A cohort model issue

Postby moudi » Fri Jun 09, 2017 9:42 am

Thanks for the suggestion. I was exactly looking for a solution for the problem you describe. I can now use the age of the cohort in the "cohort with CHD", but there is a problem with the initialization of "population with CHD". I used this construction with "head cohort", but I assume that I make a mistake there. However, I cannot sort it out, where it is exactly.
Moreover I get a warning with regard to "newCohort with CHD●Cohort". How could I get rid of this?
Thanks and regards
Test subcohort6.zip
(12.21 KiB) Downloaded 7 times


Return to “Ventity”

Who is online

Users browsing this forum: No registered users and 1 guest