Announcement

Collapse
No announcement yet.
X
  • Filter
  • Time
  • Show
Clear All
new posts

  • Question spmap

    Hi,

    I have a question about spmap. I'm just a beginner with STATA and I want to know how to use spmap for dummy variables.
    In my example I want to map the dummy variable ethnicity (1= native & 0= not native) in de resort Paramaribo (capital of Suriname)

    These are the steps (my do-file)

    spmap mean_etn2 using "Paramaribo_ressort_coord.dta", id(Suriname_ressort_ID) ///
    fcolor(Blues) osize(vvthin ..) ///
    title("Ethnicity in Paramaribo(adm. level ressort)")

    spmap mean_etn2 using "Paramaribo_ressort_coord.dta", id(Suriname_ressort_ID) ///
    fcolor(Blues) osize(vvthin ..) ///
    title("
    Ethnicity
    in Paramaribo(adm. level ressort)") ///
    clmethod(custom) clbreak(0 1 2)

    Now I want to know what the 0, 1 & 2 mean after clbreak and how I can label the legend.
    Thanks in advance!

  • #2
    Using value labels will label the legend accordingly. Using the -spmap- example datasets:
    Code:
    use "Italy-RegionsData.dta", clear
    gen majority_catholic = (relig1>50)
    label define lab1 0 "MyLabel1" 1 "MyLabel2"
    label values major lab1
    spmap majority using "Italy-RegionsCoordinates.dta", id(id) clmethod(unique)
    Click image for larger version

Name:	Graph.png
Views:	1
Size:	57.8 KB
ID:	1486069

    Comment


    • #3
      Thank you very much, I will try it once again

      Comment

      Working...
      X