Bookmark and Share

Notice: On March 31, it was announced that Statalist is moving from an email list to a forum. The old list will shut down at the end of May, and its replacement, statalist.org is already up and running.


[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: st: Disaggregating the values taken by a Stata variable


From   Sergiy Radyakin <serjradyakin@gmail.com>
To   "statalist@hsphsun2.harvard.edu" <statalist@hsphsun2.harvard.edu>
Subject   Re: st: Disaggregating the values taken by a Stata variable
Date   Fri, 31 May 2013 19:08:52 -0400

you write that you know how to do aggregation, so just do it on the
level of postal codes (extend at ellipsis with the codes) as shown
below. or if you don't have postal codes, that how do you identify the
location? merging is of course better.
Sergiy.

clear

input str6 pc str6 region
K2K0A9 Ottawa
K4K0A2 Ottawa
K4K1A4 Ottawa
K2K1A2 Ottawa
K4K1W2 Ottawa
K2W1J3 Ottawa
end

list

generate sub_reg=""
replace sub_reg="kanata" if pc=="K2K0A9" | pc=="K2K0B2" | pc=="K2K1A2"
| /*... |*/ pc=="K2W1J3"
replace sub_reg="rockland" if pc=="K4K0A2" | pc=="K4K1A4" |
pc=="K4K1A5" | /*... |*/ pc=="K4K1W2"
list

local pc_kanata " K2K0A9 K2K0B2 K2K1A2 K2K1A8 K2K1B6 K2K1C4 K2K1C8
K2K1E1 K2K1E2 K2K1E3 K2K1E5 K2K1E6 K2K1E7 K2K1G3 K2K1G8 K2K1H1 K2K1H7
K2K1H8 K2K1J2 K2K1J3 K2K1J5 K2K1J6 K2K1K1 K2K1K2 K2K1K4 K2K1K5 K2K1K6
K2K1K9 K2K1L2 K2K1L3 K2K1L7 K2K1L8 K2K1L9 K2K1M1 K2K1M3 K2K1M4 K2K1M8
K2K1M9 K2K1N1 K2K1N6 K2K1N8 K2K1P1 K2K1P3 K2K1P4 K2K1R4 K2K1S1 K2K1S4
K2K1S5 K2K1T4 K2K1V2 K2K1V3 K2K1V5 K2K1V6 K2K1V8 K2K1W1 K2K1W5 K2K1W7
K2K1X3 K2K1X6 K2K1X7 K2K1Y7 K2K1Y8 K2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K2H7G7 K2H7G8 K2H7H5 K2H7H6 K2H7J1 K2H7J5 K2H7J9 K2H7K1 K2H7K5
K2H7K8 K2H7K9 K2H7L1 K2H7L2 K2H7L5 K2H7L9 K2H7M2 K2H7M7 K2H7M9 K2H7N6
K2H7N9 K2H7P2 K2H7S9 K2H7T8 K2H7V1 K2H7W5 K2H7W7 K2H7W9 K2H7X2 K2H7X5
K2H7X9 K2H7Y8 K2H7Y9 K2H7Z1 K2H8A5 K2H8A9 K2H8B3 K2H8B8 K2H8B9 K2H8C8
K2H8E1 K2H8E9 K2H8G1 K2H8G7 K2H8H1 K2H8J1 K2H8J2 K2H8J6 K2H8J7 K2H8K2
K2H8K9 K2H8L7 K2H8M2 K2H8M6 K2H8N4 K2H8N7 K2H8N9 K2H8P6 K2H8P8 K2H8R2
K2H8R6 K2H8R8 K2H8R9 K2H8S1 K2H8S2 K2H8S3 K2H8S4 K2H8S6 K2H8S7 K2H8S8
K2H8S9 K2H8T3 K2H8T4 K2H8T6 K2H8T7 K2H8T8 K2H8T9 K2H8V3 K2H8V7 K2H8W6
K2H8W7 K2H8W8 K2H8X4 K2H8X5 K2H8X7 K2H8X8 K2H8X9 K2H8Y1 K2H8Y2 K2H8Y3
K2H8Y4 K2H8Y8 K2H8Y9 K2H9A9 K2H9B6 K2H9C4 K2H9C5 K2H9C6 K2H9C9 K2H9E7
K2H9G1 K2H9G8 K2H9H1 K2H9H4 K2H9K1 K2H9K5 K2H9K8 K2H9K9 K2H9L9 K2H9N1
K2H9N5 K2H9N6 K2H9P2 K2H9P3 K2H9P5 K2H9P9 K2H9R1 K2H9R2 K2H9R3 K2H9R4
K2H9R5 "






On Fri, May 31, 2013 at 7:21 AM,  <arir03@uqo.ca> wrote:
> Hi,
>
> I would like to know if it is possible to assign more than one value to a Stata variable under the same condition. Here is my problem:
>
> In my dataset, I have a variable called “economic_region”. I would like to:
>
> 1) assign sub-regions to each of these economic regions
> 2) assign Postal Codes (PC) or Forward Sortation Area (FSA: the first three characters of the PC) to each of these sub-regions (in order to be able to do a "many to one" match later).
>
> In other words, I would like to disaggregate these economic regions. Note that I know the list of the sub-regions for a given economic region and I also know the list of the FSA for a given sub-region, but this information is not in my dataset and I would like to include it. If I had the reverse problem (aggregation), it would be easy for me to solve. For ex, suppose that I wanted to create the economic region named Ottawa from three sub-regions: Nepean, Kanata, Rockland, it wouldbe:
>
> gen str10 economic_region = ”Ottawa” if sub_region == “Nepean” | sub_region == “Kanata” | sub_region == “Rockland”
>
> But, I want to disaggregate instead. I have the economic region named Ottawa and I want to create three sub-regions from it: Nepean, Kanata, Rockland. I thought I could do that by assigning multiple values to the variable called sub-region. I know how to assign more than one value to a Stata variable under different conditions, but I don’t know how to assign more than one value to a Stata variable under the same condition (or if this is even possible!).  Can you tell me if it is possible to do that in Stata and how? I would appreciate your help on this matter.
>
> Best,
> Ruolz.
> *
> *   For searches and help try:
> *   http://www.stata.com/help.cgi?search
> *   http://www.stata.com/support/faqs/resources/statalist-faq/
> *   http://www.ats.ucla.edu/stat/stata/

*
*   For searches and help try:
*   http://www.stata.com/help.cgi?search
*   http://www.stata.com/support/faqs/resources/statalist-faq/
*   http://www.ats.ucla.edu/stat/stata/


© Copyright 1996–2014 StataCorp LP   |   Terms of use   |   Privacy   |   Contact us   |   Site index