View Full Version : Simulating ages
duskstar
05-27-2011, 09:17 AM
This isnt so much a Stata issue as it is a statistical one. I am creating a simulation ahnd I want to simulate some plausible ages. What is the best distribution to sample from? I had assumed the normal distribution, but if so, is there anyway to restrict it in some way (like a half normal) to stop it from sampling negative values?
Dason
05-27-2011, 12:10 PM
Well it depends on what you're simulating ages for. If you're simulating a college aged group that will be different than simulating ages for people in retirement homes.
duskstar
05-31-2011, 08:44 AM
I might have solved this. I took a dataset similiar to what I wanted to create and took the mean and SD and used that to simulate from a normal distribution.
I didnt want any particular subset of ages, I wanted patients of all ages, though there were more elderly people than younger.
Dason
05-31-2011, 09:54 AM
Well if you have a dataset similar to what you want why not just sample from those ages with replacement?
duskstar
06-03-2011, 10:04 AM
Well if you have a dataset similar to what you want why not just sample from those ages with replacement?
I hadn't thought of that, I will try that. Thanks for the suggestion.
Powered by vBulletin™ Version 4.1.3 Copyright © 2013 vBulletin Solutions, Inc. All rights reserved.