So far, you have learnt to ask an RQ, design a study, and collect the data. In this chapter, you will learn how to classify the data, because this determines the analysis. You will learn to:
A diagram showing the six steps of research, arranged in a cycle: Ask, Design, Collect, Classify and summarise, Analyse, Report. Step 4 (Summarise) is highlighted, captioned βClassifying data and variablesβ.
Understanding the type of data collected is essential before summarising or analysing, because the type of data determines how to proceed. Broadly, data may be classified as either quantitative data (SectionΒ 10.2) or qualitative data (SectionΒ 10.3). The data are the recorded values of the variables, so we also talk about quantitative and qualitative variables. Quantitative variables record quantitative data; qualitative variables record qualitative data.
βAgeβ is a variable because age varies from individual to individual (DefinitionΒ 2.21). The data may include values like \(13\) months, \(21\) years and \(76\) years.
Quantitative research summarises and analyses data using numerical methods (SectionΒ 1.3). Quantitative research can involve both quantitative and qualitative data, because both can be summarised numerically (ChapterΒ 11 and ChapterΒ 12 respectively) and analysed numerically.
Section10.2Quantitative data: discrete and continuous data
Quantitative data are mathematically numerical. Most data arising from counting or measuring are quantitative. Quantitative data often (but not always) have measurement units (such as kg or cm). Be careful: numerical data are not necessarily quantitative; only mathematically numerical data are quantitative (numbers with numerical meanings).
Quantitative data are mathematically numerical: the numbers have numerical meaning, and represent quantities or amounts. Quantitative data generally arise from counting or measuring.
The number of power failures per year, the number of solar panels per home, and the number of tangelos per tree are all counts, and are quantitative variables.
Australian postcodes are four-digit numbers, but are not quantitative; the numbers are labels. A postcode of 4556 isnβt one βbetterβ or βmoreβ than a postcode of 4555. The values do not have numerical meanings. Indeed, alphabetic postcodes could have been chosen. For example, the postcode of Caboolture (Queensland) is 4510, but could have been QCAB.
Quantitative data may be further classified as discrete or continuous. Discrete quantitative data have possible values that can be counted, at least in theory. Sometimes, the possible values may have no theoretical upper limit, yet are still considered βcountableβ. Continuous quantitative data have values that cannot, at least in theory, be recorded exactly: another value can always be found between any two given values of the variable, if we measure to a greater number of decimal places. In practice, though, values must be rounded to a reasonable number of decimal places.
the number of people in passenger vehicles being driven on a certain road. Possible values: \(1\text{,}\)\(2\text{,}\)\(\text{,}\) with an upper limit of perhaps \(8\text{.}\)
Height is continuous: between the heights of \(179\) and \(180\text{,}\) many heights exist, depending on how many decimal places are used to record height. In practice, however, heights are usually rounded to the nearest centimetre for convenience. All continuous data are rounded.
the weight of \(6\)-year-old Fijian children. Values exist between any two given values of weight, by measuring to more decimal places of a kilogram. However, weights are usually reported to the nearest kilogram.
the energy consumption of houses in London. Values exist between any two given values of energy consumption, by measuring to more and more decimal places of a kiloWatt-hour (kWh). Consumption would usually be given to the nearest kWh.
the time spent in front of a computer each day for employees in a given industry. Values exist between any two given times, by measuring to more decimal places of a second. The values may be reported to the nearest minute, or the nearest \(15\text{.}\)
Annual income is discrete, since no income is between \($80 000.00\) and \($80 000.01\text{.}\) However, annual incomes are much larger than cents, and vary at scales much greater than cents, and so are often treated as continuous.
Section10.3Qualitative data: nominal and ordinal data
Qualitative data has distinct labels or categories, and are not mathematically numerical. Be careful: numerical data may be qualitative if those numbers donβt have numerical meanings. The categories of a qualitative variable are called the levels or the values of the variable.
βBrand of mobile phoneβ is a variable (as βbrandβ varies from phone to phone) that is qualitative. Many levels (i.e., brands) are possible, but could be simplified by using the levels as βAppleβ, βSamsungβ, βGoogleβ and βOtherβ.
Social Security Numbers (ssn) in the US are nine-digit numbers unique to each individual. The first three digits represent geographic regions; the next two digits are assigned to groups in that region. The last four digits are unique to individuals.
βAgeβ is a continuous quantitative variable, since age could be measured to many decimal places of a second. Age is usually rounded down to the number of completed years, for convenience. However, the age of young children may be given as β\(3\) daysβ or β\(10\) monthsβ.
Sometimes Age group is used (such as Under \(20\text{;}\)\(20\) to under \(50\text{;}\)\(50\) or over) instead of Age. βAge groupβ is qualitative. Ensure you are clear about which is used.
The levels of a variable depend on how the variable is defined. For example, the variable βHow does the person commute to workβ may have two levels: βUsing public transportβ and βNot using public transportβ.
Alternatively, the variable could be written as βDoes the person use public transport to commute to work?β For this variable, the levels are βYesβ and βNoβ.
Blood type is qualitative with four levels: Type A; Type B; Type AB; Type O. These levels have no natural order; they can be ordered alphabetically, or by prevalence. Blood type is nominal.
Age group could be listed with levels Under \(20\text{;}\)\(20\) to under \(50\text{;}\)\(50\) or over. These levels have a natural order: youngest to oldest. Age group is ordinal.
The responses will be ordinal with five levels. Giving the levels in the given order (or the reverse order) makes sense; giving the levels in alphabetical order, for example, would be very confusing. The levels have a natural order.
Consider a study to determine if the weight of \(500\) bags of pasta actually weigh \(500\) (or more) on average. One approach is to record the weight of pasta in each bag (a quantitative variable), and compare the average weight to the target weight of \(500\text{.}\)
Another approach is to record whether each bag of pasta was underweight using a balance scale. This variable would be qualitative, with two levels (underweight; not underweight). The percentage of underweight bags could be reported.
Most statistical software requires variables to be classified as quantitative or qualitative (and perhaps discrete or continuous; ordinal or nominal). This enables the software to produce appropriate output and suggest appropriate analyses.
[119] studied three rural communities in Cameroon, and recorded information about their access to water. The study could be used to determine contributors to the incidence of diarrhoea in young children (\(85\) households had children under \(5\) years of age). The variables in the WaterAccess dataset are classified in Tables TableΒ 10.22 and TableΒ 10.23.
[187] studied school-aged adolescents in Greece. Among other variables, for each child they recorded the body-mass index (weight, divided by height-squared), diet quality (poor; moderate; good), the region where they lived (Attica; Thessaloniki; Other), the number of days they performed physical exercise in the last week, and school grade.
A study recorded whether people (who were not swimming) were wearing head-protection at the beach. The results were recorded as None; Cap; or Hat. Which of the following words could be used to classify this variable: Nominal; qualitative; continuous; quantitative; ordinal.
[151] studied lime trees (Tilia cordata), and recorded these variables for \(385\) trees in Russia: the foliage biomass (in kg); the tree diameter (in cm); the age of the tree (in years); and the origin of the tree (one of Coppice, Natural, or Planted).
A study is comparing the proportion of females and males who wear hats between \(10\)am and \(2\)pm. Which one of these could be the explanatory variable?
A study is comparing the proportion of older women (aged \(40+\)) and younger women (under \(40\)) who work full-time. Which one of these could be the explanatory variable?
[135] studied body-mass index and its relationship with use of social media, and recorded these variables (among others) from a group of \(1 140\) participants:
For each variable, classify the type of variable: quantitative (discrete or continuous; what units of measurement?), or qualitative (nominal or ordinal; what levels?).
The Behavioral Risk Factor Surveillance System (brfss; [206]) survey collects data annually in all \(50\) US states, the District of Columbia and three US territories, from more than \(400 000\) adults each year. The following questions, among many others, appear in the 2023 brfss survey.
The following questions, among many others, appear in the 2021β2023 nhanes survey, and are asked about the person selected in the household (SP) to complete the questionnaire.
[309] studied the use of ankle-foot orthoses in children with cerebral palsy. Table TableΒ 10.24 gives the data for the \(15\) subjects. (gmfcs is the Gross Motor Function Classification System describing the impact of cerebral palsy on motor function; lower levels mean better functionality.) Classify the variables in the study using the language of this chapter.
[194] recorded the response of kangaroos to overhead drones (one of βNo vigilanceβ, βVigilanceβ, βFlee \(<10\)β, or βFlee \(>10\)β) and the altitude of the drone (\(30\text{,}\)\(60\text{,}\)\(100\) or \(120\)). The mob size and sex of the kangaroo was also recorded. Classify the variables in the study.
[212] studied people who died while taking selfies, and recorded the data in Table TableΒ 10.25. Which of the following are the variables in the table? For each that is a variable, classify the variable.