Page 1 of 1

Count with a two level dictionary

Posted: September 12th, 2024, 9:16 am
by AriSilva
Hi folks,
I´m having a problem using the count (or totocc) functions with a two level dictionary.
The dictionary (attached) has a first level fot the dwellng (vivienda) ahd the second level for the household (hogar) and person (persona).
The count seems not to work well, since it is counting persons where the dwelling (vivienda) is unnocupied: there are no person´s records in there.

Re: Count with a two level dictionary

Posted: September 12th, 2024, 10:34 am
by AriSilva
Just in case, attached is a file with 2 dwellings. the second one has no persons, and the count is wrong.

Re: Count with a two level dictionary

Posted: September 13th, 2024, 3:06 pm
by justinlakier
Hello,

Please see the answer to your previous question on the forums on the same topic, viewtopic.php?t=4040. We still recommend against using two-level applications. It is not certain from just the dictionary and data file provided, but it is likely that Greg's advice from 4 years ago is applicable. If this does not help, please attach your full application (or send it to cspro@lists.census.gov) so that we can check and test the code.

Hope this helps,
Justin