Content uploaded by Emil O. W. Kirkegaard
Author content
All content in this area was uploaded by Emil O. W. Kirkegaard on Mar 23, 2017
Content may be subject to copyright.
The Winnower
Originally published April 19th, 2015. Modified March 22th 2017.
Examining the S factor in Mexican states
Emil O. W. Kirkegaard1
Abstract
Two datasets of socioeconomic data was obtained from different sources. Both were factor analyzed and
revealed a general factor (S factor). These factors were highly correlated with each other (.79 to .95), HDI (.68 to
.93) and with cognitive ability (PISA; .70 to .78). The federal district was a strong outlier and excluding it
improved results.
Method of correlated vectors was strongly positive for all 4 analyses (r’s .77 to .92 with reversing).
Key words: intelligence, IQ, general socioeconomic factor, S factor, inequality, Mexico, Mexican states
1. Introduction
In a number of recent articles (Kirkegaard, 2015c, 2015b, 2015a, 2015d, 2015e), I have analyzed within-country
regional data to examine the general socioeconomic factor, if it exists in the dataset (for the origin of the term,
see e.g. Kirkegaard (2014)). This work was inspired by Lynn (2010) whose datasets I have also reanalyzed.
While doing work on another project (Fuerst & Kirkegaard, 2016), I needed an S factor for Mexican states, if
such exists. Since I was not aware of any prior analysis of this country in this fashion, I decided to do it myself.
The first problem was obtaining data for the analysis. For this, one needs a number of diverse indicators that
measure important economic and social matters for each Mexican state. Mexico has 31 states and a federal
district, so one can use a decent number of indicators to examine the S factor. Mexico is a Spanish speaking
country and English comprehension is fairly poor. According to Wikipedia, only 13% of people speak English
compared with 86% for Denmark, 64% for Germany and 35% for Egypt.2
2. S factor analysis 1 – Wikipedian data
2.1. Data source and treatment
Unlike for the previous countries, I could not easily find good data available in English. As a substitute, I used
data from Wikipedia:
•en.wikipedia.org/wiki/List_of_Mexican_states_by_unemployment
•en.wikipedia.org/wiki/List_of_Mexican_states_by_fertility_rate
1 Ulster Institute for Social Research. Email: emil@emilkirkegaard.dk
2https://en.wikipedia.org/wiki/List_of_countries_by_English-speaking_population
Page 1 of 14.
•en.wikipedia.org/wiki/List_of_Mexican_states_by_homicides
•en.wikipedia.org/wiki/List_of_Mexican_states_by_infant_mortality
•en.wikipedia.org/wiki/List_of_Mexican_states_by_life_expectancy
•en.wikipedia.org/wiki/List_of_Mexican_states_by_literacy_rate
•en.wikipedia.org/wiki/List_of_Mexican_states_by_GDP
•en.wikipedia.org/wiki/List_of_Mexican_states_by_poverty_rate
•en.wikipedia.org/wiki/List_of_Mexican_states_by_Human_Development_Index
•en.wikipedia.org/wiki/List_of_Mexican_states_by_population
•en.wikipedia.org/wiki/Ranked_list_of_Mexican_states
These come from various years, are sometimes not given per person, and often have no useful source given. So
they are of unknown veracity, but they are probably fine for a first look. The HDI is best thought of as a proxy
for the S factor, so we can use it to examine construct validity.
The variables that had data for multiple time-points were averaged.
For the variables reporting numbers in absolute numbers, I calculated per capita versions.
2.2. Results
The variables above minus HDI and population size were factor analyzed using minimum residuals to extract 1
factor. The loadings plot is shown in Figure 1.
The literacy variables had a near perfect loading on S (.99). Unemployment unexpectedly loaded positively and
so did homicides per capita altho only slightly. This could be because unemployment benefits are only in
existence in the higher S states such that going unemployed would mean starvation. The homicide loading is
possibly related to the drug war in the country.
Page 2 of 14.
Figure 1: S loadings in the Wikipedia data.
3. Analysis 2 – INEG data
3.1. Data source and treatment
Since the results based on Wikipedia data was dubious, I searched further for more data. I found it on the
Spanish-language statistical database, Instituto Nacional De Estadística Y Geografía3, which however had the
option of showing poorly done English translations. This is not optimal as there are many translation errors
which may result in choosing the wrong variable for analysis. If any Spanish-speaker reads this, I would be
happy if they would go over my chosen variables and confirm that they are correct. I ended up with the
following variables:
1. Cost of crime against individuals and households
2. Cost of crime on economic units
3. Annual percentage change of GDP at 2008 prices
4. Crime prevalence rate per 10,000 economic units
5. Crime prevalence rate per hundred thousand inhabitants aged 18 years and over, by state
6. Dark figure of crime on economic units
7. Dark figure (crimes not reported and crimes reported that were not investigated)
8. Doctors per 100 000 inhabitants
9. Economic participation of population aged 12 to 14 years
10.Economic participation of population aged 65 and over
11.Economic units.
12.Economically active population. Age 15 and older
13.Economically active population. Unemployed persons. Age 15 and older
14.Electric energy users
15.Employed population by income level. Up to one minimum wage. Age 15 and older
16.Employed population by income level. More than 5 minimum wages. Age 15 and older
17.Employed population by income level. Do not receive income. Age 15 and older
18.Fertility rate of adolescents aged 15 to 19 years
19.Female mortality rate for cervical cancer
20.Global rate of fertility
21.Gross rate of women participation
22.Hospital beds per 100 thousand inhabitants
23.Inmates in state prisons at year end
24.Life expectancy at birth
25.Literacy rate of women 15 to 24 years
26.Literacy rate of men 15 to 24 years
27.Median age
28.Nurses per 100 000 inhabitants
29.Percentage of households victims of crime
30.Percentage of births at home
31.Percentage of population employed as professionals and technicians
32.Prisoners rate (per 10,000 inhabitants age 18 and over)
33.Rate of maternal mortality (deaths per 100 thousand live births)
3http://www3.inegi.org.mx/sistemas/biinegi/Default.aspx?ii=i
Page 3 of 14.
34.Rate of inhabitants aged 18 years and over that consider their neighborhood or locality as unsafe, per
hundred thousand inhabitants aged 18 years and over
35.Rate of inhabitants aged 18 years and over that consider their state as unsafe, per hundred thousand
inhabitants aged 18 years and over
36.Rate sentenced to serve a sentence (per 1,000 population age 18 and over)
37.State Gross Domestic Product (GDP) at constant prices of 2008
38.Total population
39.Total mortality rate from respiratory diseases in children under 5 years
40.Total mortality rate from acute diarrheal diseases (ADD) in population under 5 years
41.Unemployment rate of men
42.Unemployment rate of women
43.Households
44.Inhabited housings with available computer
45.Inhabited housings that have toilet
46.Inhabited housings that have a refrigerator
47.Inhabited housings with available water from public net
48.Inhabited housings that have drainage
49.Inhabited housings with available electricity
50.Inhabited housings that have a washing machine
51.Inhabited housings with television
52.Percentage of housing with piped water
53.Percentage of housing with electricity
54.Proportion of population with access to improved sanitation, urban and rural
55.Proportion of population with sustainable access to improved sources of water supply, in urban and rural
areas
There were data for multiple years for most of them. I used all data from the last 10 years approximately. For all
data with multiple years, I calculated the mean value.
For data given in raw numbers, I calculated the appropriate per unit measures (per person, per economically
active person (?), per household).
A matrix plot for all the S factor relevant data (e.g. not population size) is shown in Figure 2. It shows missing
data in red, as well as the relative difference between datapoints. Thus, cells that are completely white or black
are outliers compared to the other data.
Page 4 of 14.
One variable (inmates per person) had a few missing datapoints.
Multiple other variables had strong outliers. I examined these to determine if they were real or due to data error.
Inspection revealed that the GDP per person data was clearly incorrect for one state (Campeche) but I could not
find the source of error. The data is the same as on the website and did not match the data on Wikipedia. I deleted
it to be safe.
The GDP change outlier seems to be real (Campeche) which has negative growth. According to a Mexican blog4,
it is due to its oil fields closing.
The rest of the outliers were hard to say something about due to the odd nature of the data (“dark crime”?), or
were plausible. E.g. Mexico City (Federal District, the capital) was an outlier on nurses and doctors per capita,
but this is presumably due to many large hospitals being located there.
3.2. Factor analysis
Since there were only 32 cases — 31 states + federal district — and 47 variables (excluding the bogus GDP per
capita), this gives problems for factor analysis. There are various recommendations, but almost none of them are
met by this dataset (Zhao, 2009). To test limits, I decided to try factor analyzing all of the variables. This
produced warnings such as:
The estimated weights for the factor scores are probably incorrect. Try a different factor
extraction method.
In factor.scores, the correlation matrix is singular, an approximation is used
In cor.smooth(R) : Matrix was not positive definite, smoothing was done
In cor.smooth(R) : Matrix was not positive definite, smoothing was done
In cor.smooth(r) : Matrix was not positive definite, smoothing was done
4http://geo-mexico.com/?p=12070
Page 5 of 14.
Figure 2: Matrixplot of S data from INEG.
In cor.smooth(r) : Matrix was not positive definite, smoothing was done
Such warnings do not always mean that the result is nonsense, but they often do. For that reason, I wanted to
extract an S factor with a smaller number of variables. From the 47, I selected the following 21 variables as
generally representative and interpretable. These were:
1. GDP.change, #Economic
2. Unemploy.men.rate,
3. Unemploy.women.rate,
4. Low.income.peap,
5. High.income.peap,
6. Prof.tech.employ.pct,
7. crime.rate.per.adult, #crime
8. Inmates.per.pers,
9. Unsafe.neighborhood.percept.rate,
10. Has.water.net.per.hh, #material goods
11. Elec.pct,
12. Has.wash.mach.per.hh,
13. Doctors.per.pers, #Health
14. Nurses.per.pers,
15. Hospital.beds.per.pers,
16. Total.fertility,
17. Home.births.pct,
18. Maternal.death.rate,
19. Life.expect,
20. Women.participation, #Gender equality
21. Lit.young.women #education
Note that peap = per economically active person, hh = household.
The selection was made by my judgment call and others may choose different variables.
3.3. Automatic reduction of dataset
As a robustness check and evidence against a possible claim that I picked the variables such as to get an S factor
that most suited my prior beliefs, I decided to find an automatic method of selecting a subset of variables for
factor analysis. I noticed that in the original dataset, some variables overlapped near perfectly. This would mean
that whatever they measure, it would get measured twice or more when extracting a factor. Highly correlated
variables can also create nonsense solutions, especially when extracting more than 1 factor.
Another piece of insight comes from the fact that for cognitive data, general factors extracted from a less broad
selection of subtests are worse measures of general cognitive ability than those from broader selections (Johnson,
te Nijenhuis, & Bouchard, 2008).
Lastly, subtests from different domains tend to be less correlated than those from the same domain (hence the
existence of group factors).
Combining all this, it seems a decent idea that to reduce a dataset by 1 variable, one should calculate all the
intercorrelations and find the highest one. Then one should remove one of the variables responsible for it. One
Page 6 of 14.
can do this repeatedly to remove more than 1 variable from a dataset. Concerning the question of which of the
two variables to remove, I can think of three ways: always removing the first, always the second, choosing at
random. I implemented all three settings and chose the second as the default. This is because in many datasets
the first of a set of highly correlated variables is usually the ‘primary one’, E.g. unemployment, unemployment
men, unemployment women. The algorithm also outputs step-by-step information concerning which variables
was removed and what their correlation was.
Having written the R code for the algorithm, I ran it on the Mexican dataset. I wanted to obtain a solution using
the largest possible number of variables without getting a warning from the factor extraction function. So I first
removed 1 variable, and then ran the factor analysis. When I received an error, I removed another, and so on.
After having removed 20 variables, I no longer received an error. This left the analysis with 27 variables, or 6
more than my chosen selection.
Analysis of the output from the algorithm shows that the function works. In most cases, the pair of variables
found was either a (near-)double measure e.g. percent of population with electricity and percent of households
with electricity, or closely related e.g. literacy in men and women. Sometimes however, the pair did not seem to
be closely related, e.g. women’s participation and percent of households with a computer.
Since this dataset selected the variable with missing data, I used the irmi() function from the VIM package to
impute the missing data (Templ, Alfons, Kowarik, & Prantner, 2015).
3.4. Factor loadings: stability
The factor loading plots are shown in Figures 3-5.
Page 7 of 14.
Figure 3: S factor loadings in the INEG data. All variables.
Each analysis relied upon a unique but overlapping selection of variables. Thus, it is possible to correlate the
loadings of the overlapping parts for each analysis. This is a measure of loading stability in different factor
analytic environments, as also done by Ree and Earles (1991) for general cognitive ability factor (g factor). The
correlations were .98, 1.00, .98 (n’s 21, 27, 12), showing very high stability across datasets. Note that it was not
possible to use the loadings from the Wikipedian data factor analysis because the variables were not strictly
speaking overlapping.
Page 8 of 14.
Figure 4: S factor loadings in the INEG data. Chosen variables.
Figure 5: S factor loadings in the INEG data. Automatically chosen
variables.
3.5. Factor loadings: interpretation
Examining the factor loadings reveals some things of interest. Generally for all analyses, whatever that is
generally considered good loads positively, and whatever considered bad loads negatively.
Unemployment (together, men, women) has positive loadings, whereas it ‘should’ have negative loadings. This
is perhaps because the lower S factor states have more dysfunctional or no social security nets such that not
working means starvation, and that this keeps people from not working. This is merely a conjecture because I
don’t know much about Mexico. Hopefully someone more knowledgeable than me will read this and have a
better answer.
Crime variables (crime rate, victimization, inmates/prisoner per capita, sentencing rate) load positively whereas
they should have negative. This pattern has been found before, see Kirkegaard (2015e) for a review of S factor
studies and crime variables.
3.6. Factor scores
Next I correlated the factor scores from all 4 analysis with each other as well as HDI and cognitive ability as
measured by PISA tests (the cognitive data is from Fuerst & Kirkegaard, 2016; the HDI data is from Wikipedia).
The correlation matrix is shown in Table 1.
S all S chosen
S
automatic S wiki HDI mean
Cognitive
ability
S all 1.00 -0.08 -0.04 0.08 -0.17 -0.12
S chosen -0.08 1.00 0.94 0.83 0.93 0.65
S automatic -0.04 0.94 1.00 0.91 0.89 0.74
S wiki 0.08 0.83 0.91 1.00 0.76 0.78
HDI mean -0.17 0.93 0.89 0.76 1.00 0.53
Cognitive
ability -0.12 0.65 0.74 0.78 0.53 1.00
Table 1: Primary results – original scoring.
Strangely, despite the similar factor loadings, the factor scores from the S factor extracted from all the variables
(S.all) had about no relation to the others. This probably indicates that the factor scoring method could not
handle this type of odd case. The default scoring method for the factor analysis is “regression”, but there are a
few others. Bartlett’s method yielded results for S.all that fit with the other factors, while none of the other
scoring methods did. See the psych package documentation for details about this method (Revelle, 2015). I
changed the extraction method for all the other analyses to Bartlett’s to remove method specific variance. The
new correlation table is shown in Table 2:
S all S chosen S automatic S wiki HDI mean Cognitive ability
S all 1.00 0.96 0.99 0.93 0.86 0.76
S chosen 0.96 1.00 0.96 0.86 0.93 0.70
S automatic 0.99 0.96 1.00 0.91 0.88 0.76
S wiki 0.93 0.86 0.91 1.00 0.75 0.78
Page 9 of 14.
HDI mean 0.86 0.93 0.88 0.75 1.00 0.53
Cognitive ability 0.76 0.70 0.76 0.78 0.53 1.00
Table 2: Primary results – Bartlett scoring.5
Intriguingly, now all the correlations are stronger. Perhaps Bartlett’s method is better for handling this type of
extraction involving general factors from datasets with low case to variable ratios. It certainly deserves empirical
investigation, including reanalysis of prior datasets. I reran the earlier parts of this paper with the Bartlett
method. It did not substantially change results. The correlations between loadings across analysis increased a bit
(to .98, 1.00, .99).
One possibility however is that the stronger results is just due to Bartlett’s method creating outliers that happen
to lie on the regression line. Examination of the scatterplots revealed that this was not the case.
3.7. S factor scores and cognitive ability
The next question is to what degree the within country differences in Mexico can be explained by cognitive
ability. The correlations are in the above table as well, they are in the region .70 to .78 for the various S factors.
In other words, fairly high. One could plot all of them vs. cognitive ability, but that would give us 4 plots.
Instead, I plot only the S factor from my chosen variables, shown in Figure 6, since this has the highest
correlation with HDI and thus the best claim for construct validity. It is also the most conservative option
because of the 4 S factors, it has the lowest correlation with cognitive ability.
5 These results originally had somewhat weaker S intercorrelations, e.g. S.all x S.chosen = .79. I could not replicate this result, but it
matters little because the interpretation is about the same. It may be an error in the original write-up.
Page 10 of 14.
We see that the federal district is a strong outlier, just like in the study with US states and Washington DC
(Kirkegaard, 2015a). One should then remove it and rerun all the analyses. This includes the S factor extractions
because the presence of a strong ‘mixed case’ (to be explained further in a future publication) affects the S factor
extracted (ibid.).
4. Analyses without Federal District
I reran all the analyses without the federal district. The loading correlations increased slightly to 1.00.
The factor score correlations, shown in Table 3 below, increased meaning that the Federal District outlier was a
source of discrepancy between the extraction methods. After this is resolved, the S factors from the INEG dataset
are in near-perfect agreement (1.00, .99, .99) while the one from Wikipedia data is less so but still respectable
(.93, .93, .91). Correlations with cognitive ability also improved.
S all S chosen
S
automatic S wiki HDI mean
Cognitive
ability
S all 1.00 1.00 0.99 0.93 0.85 0.78
S chosen 1.00 1.00 0.99 0.93 0.87 0.81
S automatic 0.99 0.99 1.00 0.91 0.89 0.79
S wiki 0.93 0.93 0.91 1.00 0.75 0.77
Page 11 of 14.
Figure 6: Cognitive ability and S factor (based on chosen variables).
HDI mean 0.85 0.87 0.89 0.75 1.00 0.56
Cognitive
ability 0.78 0.81 0.79 0.77 0.56 1.00
Table 3: Primary results. Federal District excluded. Bartlett's scoring.
Figure 7 shows the scatterplot of cognitive ability and S (chosen).
4.1. Method of correlated vectors (MCV)
In line with earlier studies, I examined whether the measures that are better measures of the latent S factor are
also correlated more highly with the criterion variable, cognitive ability. Indicators with negative loadings were
reversed to avoid inflation the correlation. Figure 8 shows the MCV scatterplot for the analysis with the chosen
variables.
Page 12 of 14.
Figure 7: Cognitive ability and S (chosen variables). Federal District excluded.
The MCV results are strong: .90 .77 .92 and .92 for the analysis with all variables, chosen variables,
automatically chosen variables and Wikipedian variables respectively. Note that these are for the analyses
without the federal district, but they were similar with it too.
5. Discussion and conclusion
Generally, the present analysis found similar findings to earlier studies, especially the study pf US states
(Kirkegaard, 2015a). Cognitive ability was a very strong correlate of the S factors, especially once the federal
district outlier was excluded. Further work is needed to find out why unemployment and crime variables
sometimes load positively in S factor analyses with regions or states as the unit of analysis.
MCV analysis supported the idea that cognitive ability is related to the S factor, not just some non-S factor
source of variance also present in the dataset.
Supplementary material and acknowledgments
Supplementary materials including code, high quality figures and data can be found at https://osf.io/zk3yx/.
References
Fuerst, J., & Kirkegaard, E. O. W. (2016). Admixture in the Americas: Regional and national differences.
Page 13 of 14.
Figure 8: MCV scatterplot of S (chosen) and cognitive ability. Federal District excluded.
Mankind Quarterly.
Johnson, W., te Nijenhuis, J., & Bouchard, T. J. (2008). Still just 1 g: Consistent results from five test batteries.
Intelligence, 36(1), 81–95.
Kirkegaard, E. O. W. (2014). The international general socioeconomic factor: Factor analyzing international
rankings. Open Differential Psychology. Retrieved from http://openpsych.net/ODP/2014/09/the-
international-general-socioeconomic-factor-factor-analyzing-international-rankings/
Kirkegaard, E. O. W. (2015a). Examining the S factor in US states. The Winnower. Retrieved from
https://thewinnower.com/papers/examining-the-s-factor-in-us-states
Kirkegaard, E. O. W. (2015b). Indian states: G and S factors. The Winnower. Retrieved from
https://thewinnower.com/papers/indian-states-g-and-s-factors
Kirkegaard, E. O. W. (2015c). S and G in Italian regions: Re-analysis of Lynn’s data and new data. The
Winnower. Retrieved from https://thewinnower.com/papers/s-and-g-in-italian-regions-re-analysis-of-
lynn-s-data-and-new-data
Kirkegaard, E. O. W. (2015d). The S factor in China. The Winnower. Retrieved from
https://thewinnower.com/papers/the-s-factor-in-china
Kirkegaard, E. O. W. (2015e). The S factor in the British Isles: A reanalysis of Lynn (1979). The Winnower.
Retrieved from https://thewinnower.com/papers/the-s-factor-in-the-british-isles-a-reanalysis-of-lynn-
1979
Lynn, R. (2010). In Italy, north–south differences in IQ predict differences in income, education, infant mortality,
stature, and literacy. Intelligence, 38(1), 93–100. https://doi.org/10.1016/j.intell.2009.07.004
Ree, M. J., & Earles, J. A. (1991). The stability of g across different methods of estimation. Intelligence, 15(3),
271–278. https://doi.org/10.1016/0160-2896(91)90036-D
Revelle, W. (2015). psych: Procedures for Psychological, Psychometric, and Personality Research (Version
1.5.4). Retrieved from http://cran.r-project.org/web/packages/psych/index.html
Templ, M., Alfons, A., Kowarik, A., & Prantner, B. (2015, February 19). VIM: Visualization and Imputation of
Missing Values. CRAN. Retrieved from http://cran.r-project.org/web/packages/VIM/index.html
Zhao, N. (2009, March 23). The Minimum Sample Size in Factor Analysis. Retrieved November 16, 2016, from
https://www.encorewiki.org/display/~nzhao/The+Minimum+Sample+Size+in+Factor+Analysis
Page 14 of 14.