Is CCA possible with categorical environmental variables?

1,294 views
Skip to first unread message

Bo San

unread,
Apr 3, 2014, 2:33:41 AM4/3/14
to pc-...@googlegroups.com
 Hello Bruce,
I have a species data set with environmental variables. Some environmental variables are quantitative but some are categorical. I would like to know if it is logically meaningful to perform a CCA with categorical environmental variables like slope aspect (e.g., southeast =1, southwest=2,northeast=3, northwest=4).

Thank you in advance.
 
Bo Sann
Kyoto University

Bruce McCune

unread,
Apr 3, 2014, 10:39:18 AM4/3/14
to pc-...@googlegroups.com
Bo Sann, If the categoricals form a logical, pseudo-quantitative order (like hottest slopes to cooleest slopes) you can code the categories accordingly and treat it as a quantitative variable. Otherwise, you need to restructure this into several binary indicator variables (one less than the number of categories). Each new variable would code 0=no and 1=yes for a given category.
Bruce McCune
--
You received this message because you are subscribed to the Google Groups "PC-ORD" group.
To unsubscribe from this group and stop receiving emails from it, send an email to pc-ord+un...@googlegroups.com.
For more options, visit https://groups.google.com/d/optout.

Bo San

unread,
Apr 3, 2014, 11:18:19 PM4/3/14
to pc-...@googlegroups.com
Thanks Bruce for your kind reply.
My example environment data is as follows:

Sample plot    Slope aspect
   A                    NE (north-east)
   B                    NE
   C                    SE (south-east)
   D                    SE
   E                    NW (north-west)
   F                    NW
   G                    SW (south-west)
   H                    SW

As you suggested, I will change my data as follows:

  Sample plot   Aspect (NE)   Aspect(SE)     Aspect(NW)   Aspect(SW)
      A                      1                    0                          0                    0
      B                      1                    0                          0                    0
      C                      0                    1                          0                    0
      D                      0                    1                          0                    0
      E                      0                    0                          1                    0
      F                      0                    0                          1                    0
      G                      0                    0                          0                    1
      H                      0                    0                          0                    1

If so, is my understanding correct?

Thanks a million, Bruce. You always supported me although we have never met each other.
To unsubscribe from this group and stop receiving emails from it, send an email to pc-ord+u...@googlegroups.com.

Bruce McCune

unread,
Apr 6, 2014, 11:06:59 AM4/6/14
to pc-...@googlegroups.com
Your coding scheme looks ok, except that if you are going to use these as predictors in a regression-like step (e.g. RDA or CCA), you should leave out one category. For example, you could drop the "SW" variable, since it is already coded by "absence" of all other aspects.

Thanks for your nice comments.

-Bruce McCune
To unsubscribe from this group and stop receiving emails from it, send an email to pc-ord+un...@googlegroups.com.

Bo San

unread,
Apr 6, 2014, 10:33:27 PM4/6/14
to pc-...@googlegroups.com
Thanks for your patient reply, Bruce.
     I clearly understand that I should leave out one variable in my example data above. But how about a CCA with both quantitative and categorical environmental variables?
     I have an environmental second matrix not only with  slope aspect (NE, SE, NW, SW) variables but also with other quantitative topographic variables (slope, landform index,etc.). If I do a CCA with the quantitative environmental  variables and categorical variables (slope aspect) , should I also drop one dummy variable (e.g., the SW variable)?

Thank again for your time.
Bo Sann

Bruce McCune

unread,
Apr 7, 2014, 10:48:11 AM4/7/14
to pc-...@googlegroups.com
Yes, even if those indicator (dummy) variables are accompanied by other predictors in CCA, you should drop one of the indicator variables.
-Bruce
--
To unsubscribe from this group and stop receiving emails from it, send an email to pc-ord+un...@googlegroups.com.

Bo San

unread,
Apr 7, 2014, 8:50:00 PM4/7/14
to pc-...@googlegroups.com
 For example , if I include all the dummy variables , I can display the results of correlations with the CCA axes scores as follows:
   
          Aspect Variables               Axis 1         Axis 2
                  North-east                        0.1245          0.2367
                  North-west                       0.2568          0.3578
                  South-east                       0.2678          0.1864
                  South-west                      0.8025          0.6012

 In the above example correlations, I can interpret slope aspect (south-west) is strongly related with both axes. If I happen to remove the strong variables  (like south-west in the above example), my interpretation will be misleading like that slope aspect is not related to vegetation pattern in the ordination.
      (i) I supposed that  it is necessary to display  the correlation results of the removed variable to make interpretation?
      (ii) How should I solve that kind of problem?

Is my understanding wrong with this kind of dummy environmental variables in case of CCA?

Bruce McCune

unread,
Apr 8, 2014, 12:12:53 PM4/8/14
to pc-...@googlegroups.com
Bo Sann,

You are right that your choice of which of the dummy variables to remove can facilitate or hinder interpretation. But regardless of which one you remove, all of the information is contained in 3 of the 4 variables. If the effect is most clearly shown by retaining SW, by all means retain that one.

Bruce McCune
To unsubscribe from this group and stop receiving emails from it, send an email to pc-ord+un...@googlegroups.com.

Bo San

unread,
Apr 8, 2014, 8:33:38 PM4/8/14
to pc-...@googlegroups.com
Thank you so much. From now, I will apply the knowledge I gained for my journal paper.
Reply all
Reply to author
Forward
0 new messages