This document discusses different types of data in statistics and R. It describes descriptive statistics, which involves collecting, presenting, and describing data, and inferential statistics, which draws conclusions about populations based on sample data. It then defines qualitative, quantitative, discrete, continuous, and time series data. Finally, it outlines the different data types that can be used in R, including numeric, integer, character, factor, and logical data as well as dates and times.
Data Mining: Concepts and Techniques (3rd ed.)- Chapter 3 preprocessingSalah Amean
the chapter contains :
Data Preprocessing: An Overview,
Data Quality,
Major Tasks in Data Preprocessing,
Data Cleaning,
Data Integration,
Data Reduction,
Data Transformation and Data Discretization,
Summary.
Data Mining: Concepts and Techniques (3rd ed.)- Chapter 3 preprocessingSalah Amean
the chapter contains :
Data Preprocessing: An Overview,
Data Quality,
Major Tasks in Data Preprocessing,
Data Cleaning,
Data Integration,
Data Reduction,
Data Transformation and Data Discretization,
Summary.
An Efficient Annotation of Search Results Based on Feature Ranking Approach f...Computer Science Journals
With the increased number of web databases, major part of deep web is one of the bases of database. In several search engines, encoded data in the returned resultant pages from the web often comes from structured databases which are referred as Web databases (WDB).
Machine learning is a subfield of computer science that evolved from the study of pattern recognition and computational learning theory in artificial intelligence. Machine learning explores the study and construction of algorithms that can learn from and make predictions on data.
Data Science - Part II - Working with R & R studioDerek Kane
This tutorial will go through a basic primer for individuals who want to get started with predictive analytics through downloading the open source (FREE) language R. I will go through some tips to get up and started and building predictive models ASAP.
Data Mining DataLecture Notes for Chapter 2IntroducOllieShoresna
Data Mining: Data
Lecture Notes for Chapter 2
Introduction to Data Mining
by
Tan, Steinbach, Kumar
What is Data?Collection of data objects and their attributes
An attribute is a property or characteristic of an objectExamples: eye color of a person, temperature, etc.Attribute is also known as variable, field, characteristic, or featureA collection of attributes describe an objectObject is also known as record, point, case, sample, entity, or instance
Attributes
Objects
Attribute ValuesAttribute values are numbers or symbols assigned to an attribute
Distinction between attributes and attribute valuesSame attribute can be mapped to different attribute values Example: height can be measured in feet or meters
Different attributes can be mapped to the same set of values Example: Attribute values for ID and age are integers But properties of attribute values can be different
ID has no limit but age has a maximum and minimum value
Types of Attributes There are different types of attributesNominalExamples: ID numbers, eye color, zip codesOrdinalExamples: rankings (e.g., taste of potato chips on a scale from 1-10), grades, height in {tall, medium, short}IntervalExamples: calendar dates, temperatures in Celsius or Fahrenheit.RatioExamples: temperature in Kelvin, length, time, counts
Properties of Attribute Values The type of an attribute depends on which of the following properties it possesses:Distinctness: = Order: < > Addition: + - Multiplication: * /
Nominal attribute: distinctnessOrdinal attribute: distinctness & orderInterval attribute: distinctness, order & additionRatio attribute: all 4 properties
Attribute Type
Description
Examples
Operations
Nominal
The values of a nominal attribute are just different names, i.e., nominal attributes provide only enough information to distinguish one object from another. (=, )
zip codes, employee ID numbers, eye color, sex: {male, female}
mode, entropy, contingency correlation, 2 test
Ordinal
The values of an ordinal attribute provide enough information to order objects. (<, >)
hardness of minerals, {good, better, best},
grades, street numbers
median, percentiles, rank correlation, run tests, sign tests
Interval
For interval attributes, the differences between values are meaningful, i.e., a unit of measurement exists.
(+, - )
calendar dates, temperature in Celsius or Fahrenheit
mean, standard deviation, Pearson's correlation, t and F tests
Ratio
For ratio variables, both differences and ratios are meaningful. (*, /)
temperature in Kelvin, monetary quantities, counts, age, mass, length, electrical current
geometric mean, harmonic mean, percent variation
Attribute Level
Transformation
Comments
Nominal
Any permutation of values
If all employee ID numbers were reassigned, would it make any difference?
Ordinal
An order preserving change of values, i.e.,
new_value = f(old_value)
where f is a monotonic function.
An attribut ...
An Efficient Annotation of Search Results Based on Feature Ranking Approach f...Computer Science Journals
With the increased number of web databases, major part of deep web is one of the bases of database. In several search engines, encoded data in the returned resultant pages from the web often comes from structured databases which are referred as Web databases (WDB).
Machine learning is a subfield of computer science that evolved from the study of pattern recognition and computational learning theory in artificial intelligence. Machine learning explores the study and construction of algorithms that can learn from and make predictions on data.
Data Science - Part II - Working with R & R studioDerek Kane
This tutorial will go through a basic primer for individuals who want to get started with predictive analytics through downloading the open source (FREE) language R. I will go through some tips to get up and started and building predictive models ASAP.
Data Mining DataLecture Notes for Chapter 2IntroducOllieShoresna
Data Mining: Data
Lecture Notes for Chapter 2
Introduction to Data Mining
by
Tan, Steinbach, Kumar
What is Data?Collection of data objects and their attributes
An attribute is a property or characteristic of an objectExamples: eye color of a person, temperature, etc.Attribute is also known as variable, field, characteristic, or featureA collection of attributes describe an objectObject is also known as record, point, case, sample, entity, or instance
Attributes
Objects
Attribute ValuesAttribute values are numbers or symbols assigned to an attribute
Distinction between attributes and attribute valuesSame attribute can be mapped to different attribute values Example: height can be measured in feet or meters
Different attributes can be mapped to the same set of values Example: Attribute values for ID and age are integers But properties of attribute values can be different
ID has no limit but age has a maximum and minimum value
Types of Attributes There are different types of attributesNominalExamples: ID numbers, eye color, zip codesOrdinalExamples: rankings (e.g., taste of potato chips on a scale from 1-10), grades, height in {tall, medium, short}IntervalExamples: calendar dates, temperatures in Celsius or Fahrenheit.RatioExamples: temperature in Kelvin, length, time, counts
Properties of Attribute Values The type of an attribute depends on which of the following properties it possesses:Distinctness: = Order: < > Addition: + - Multiplication: * /
Nominal attribute: distinctnessOrdinal attribute: distinctness & orderInterval attribute: distinctness, order & additionRatio attribute: all 4 properties
Attribute Type
Description
Examples
Operations
Nominal
The values of a nominal attribute are just different names, i.e., nominal attributes provide only enough information to distinguish one object from another. (=, )
zip codes, employee ID numbers, eye color, sex: {male, female}
mode, entropy, contingency correlation, 2 test
Ordinal
The values of an ordinal attribute provide enough information to order objects. (<, >)
hardness of minerals, {good, better, best},
grades, street numbers
median, percentiles, rank correlation, run tests, sign tests
Interval
For interval attributes, the differences between values are meaningful, i.e., a unit of measurement exists.
(+, - )
calendar dates, temperature in Celsius or Fahrenheit
mean, standard deviation, Pearson's correlation, t and F tests
Ratio
For ratio variables, both differences and ratios are meaningful. (*, /)
temperature in Kelvin, monetary quantities, counts, age, mass, length, electrical current
geometric mean, harmonic mean, percent variation
Attribute Level
Transformation
Comments
Nominal
Any permutation of values
If all employee ID numbers were reassigned, would it make any difference?
Ordinal
An order preserving change of values, i.e.,
new_value = f(old_value)
where f is a monotonic function.
An attribut ...
Brief introduction to Data and its types.
There are different types of data in Statistics, that are collected, analysed, interpreted and presented. The data are the individual pieces of factual information recorded, and it is used for the purpose of the analysis process. The two processes of data analysis are interpretation and presentation. Statistics are the result of data analysis. Data classification and data handling are important processes as it involves a multitude of tags and labels to define the data, its integrity and confidentiality. In this article, we are going to discuss the different types of data in statistics in detail.
The data is classified into majorly four categories:
Nominal data
Ordinal data
Discrete data
Continuous data
Qualitative or Categorical Data
Qualitative data, also known as the categorical data, describes the data that fits into the categories. Qualitative data are not numerical. The categorical information involves categorical variables that describe the features such as a person’s gender, home town etc. Categorical measures are defined in terms of natural language specifications, but not in terms of numbers.
Sometimes categorical data can hold numerical values (quantitative value), but those values do not have a mathematical sense. Examples of the categorical data are birthdate, favourite sport, school postcode. Here, the birthdate and school postcode hold the quantitative value, but it does not give numerical meaning.
Nominal Data
Nominal data is one of the types of qualitative information which helps to label the variables without providing the numerical value. Nominal data is also called the nominal scale. It cannot be ordered and measured. But sometimes, the data can be qualitative and quantitative. Examples of nominal data are letters, symbols, words, gender etc.
The nominal data are examined using the grouping method. In this method, the data are grouped into categories, and then the frequency or the percentage of the data can be calculated. These data are visually represented using the pie charts.
Ordinal Data
Ordinal data/variable is a type of data that follows a natural order. The significant feature of the nominal data is that the difference between the data values is not determined. This variable is mostly found in surveys, finance, economics, questionnaires, and so on.
The ordinal data is commonly represented using a bar chart. These data are investigated and interpreted through many visualisation tools. The information may be expressed using tables in which each row in the table shows the distinct category.
Quantitative or Numerical Data
Quantitative data is also known as numerical data which represents the numerical value (i.e., how much, how often, how many). Numerical data gives information about the quantities of a specific thing. Some examples of numerical data are height, length, size, weight, and so on. The quantitative data can be classified into two different types based on the data
Categorical DataCategorical data represents characteristics..docxketurahhazelhurst
Categorical Data
Categorical data represents characteristics. Therefore it can represent things like a person’s gender, language etc. Categorical data can also take on numerical values (Example: 1 for female and 0 for male). Note that those numbers don’t have mathematical meaning.
Nominal Data
Nominal values represent discrete units and are used to label variables, that have no quantitative value. Just think of them as „labels“. Note that nominal data that has no order. Therefore if you would change the order of its values, the meaning would not change. You can see two examples of nominal features below:
The left feature that describes a persons gender would be called „dichotomous“, which is a type of nominal scales that contains only two categories.
Ordinal Data
Ordinal values represent discrete and ordered units. It is therefore nearly the same as nominal data, except that it’s ordering matters. You can see an example below:
Note that the difference between Elementary and High School is different than the difference between High School and College. This is the main limitation of ordinal data, the differences between the values is not really known. Because of that, ordinal scales are usually used to measure non-numeric features like happiness, customer satisfaction and so on.
Numerical Data
1. Discrete Data
We speak of discrete data if its values are distinct and separate. In other words: We speak of discrete data if the data can only take on certain values. This type of data can’t be measured but it can be counted. It basically represents information that can be categorized into a classification. An example is the number of heads in 100 coin flips.
You can check by asking the following two questions whether you are dealing with discrete data or not: Can you count it and can it be divided up into smaller and smaller parts?
2. Continuous Data
Continuous Data represents measurements and therefore their values can’t be counted but they can be measured. An example would be the height of a person, which you can describe by using intervals on the real number line.
Interval Data
Interval values represent ordered units that have the same difference. Therefore we speak of interval data when we have a variable that contains numeric values that are ordered and where we know the exact differences between the values. An example would be a feature that contains temperature of a given place like you can see below:
The problem with interval values data is that they don’t have a „true zero“. That means in regards to our example, that there is no such thing as no temperature. With interval data, we can add and subtract, but we cannot multiply, divide or calculate ratios. Because there is no true zero, a lot of descriptive and inferential statistics can’t be applied.
Ratio Data
Ratio values are also ordered units that have the same difference. Ratio values are the same as interval values, with the difference that they do have an absolute zero. Good e ...
Data Mining Exploring DataLecture Notes for Chapter 3OllieShoresna
Data Mining: Exploring Data
Lecture Notes for Chapter 3
Introduction to Data Mining
by
Tan, Steinbach, Kumar
What is data exploration?Key motivations of data exploration includeHelping to select the right tool for preprocessing or analysisMaking use of humans’ abilities to recognize patterns People can recognize patterns not captured by data analysis tools
Related to the area of Exploratory Data Analysis (EDA)Created by statistician John TukeySeminal book is Exploratory Data Analysis by TukeyA nice online introduction can be found in Chapter 1 of the NIST Engineering Statistics Handbook
http://www.itl.nist.gov/div898/handbook/index.htm
A preliminary exploration of the data to better understand its characteristics.
Techniques Used In Data Exploration In EDA, as originally defined by TukeyThe focus was on visualizationClustering and anomaly detection were viewed as exploratory techniquesIn data mining, clustering and anomaly detection are major areas of interest, and not thought of as just exploratory
In our discussion of data exploration, we focus onSummary statisticsVisualizationOnline Analytical Processing (OLAP)
Iris Sample Data Set Many of the exploratory data techniques are illustrated with the Iris Plant data set.Can be obtained from the UCI Machine Learning Repository
http://www.ics.uci.edu/~mlearn/MLRepository.htmlFrom the statistician Douglas FisherThree flower types (classes): Setosa Virginica VersicolourFour (non-class) attributes Sepal width and length Petal width and length
Virginica. Robert H. Mohlenbrock. USDA NRCS. 1995. Northeast wetland flora: Field office guide to plant species. Northeast National Technical Center, Chester, PA. Courtesy of USDA NRCS Wetland Science Institute.
Summary StatisticsSummary statistics are numbers that summarize properties of the data
Summarized properties include frequency, location and spread Examples: location - mean
spread - standard deviation
Most summary statistics can be calculated in a single pass through the data
Frequency and ModeThe frequency of an attribute value is the percentage of time the value occurs in the
data set For example, given the attribute ‘gender’ and a representative population of people, the gender ‘female’ occurs about 50% of the time.The mode of a an attribute is the most frequent attribute value The notions of frequency and mode are typically used with categorical data
PercentilesFor continuous data, the notion of a percentile is more useful.
Given an ordinal or continuous attribute x and a number p between 0 and 100, the pth percentile is a value of x such that p% of the observed values of x are less than .
For instance, the 50th percentile is the value such that 50% of all values of x are less than .
Measures of Location: Mean and MedianThe mean is the most common measure of the location of a set of points. However, the mean is very sensitive to outliers. ...
Please Subscribe to this Channel for more solutions and lectures
http://www.youtube.com/onlineteaching
Chapter 1: Introduction to Statistics
Section 1.2: Types of Data, Key Concept
Data Mining DataLecture Notes for Chapter 2Introduc.docxwhittemorelucilla
Data Mining: Data
Lecture Notes for Chapter 2
Introduction to Data Mining
by
Tan, Steinbach, Kumar
What is Data?Collection of data objects and their attributes
An attribute is a property or characteristic of an objectExamples: eye color of a person, temperature, etc.Attribute is also known as variable, field, characteristic, or featureA collection of attributes describe an objectObject is also known as record, point, case, sample, entity, or instance
Attributes
Objects
Attribute ValuesAttribute values are numbers or symbols assigned to an attribute
Distinction between attributes and attribute valuesSame attribute can be mapped to different attribute values Example: height can be measured in feet or meters
Different attributes can be mapped to the same set of values Example: Attribute values for ID and age are integers But properties of attribute values can be different
ID has no limit but age has a maximum and minimum value
Measurement of Length The way you measure an attribute is somewhat may not match the attributes properties.
Types of Attributes There are different types of attributesNominalExamples: ID numbers, eye color, zip codesOrdinalExamples: rankings (e.g., taste of potato chips on a scale from 1-10), grades, height in {tall, medium, short}IntervalExamples: calendar dates, temperatures in Celsius or Fahrenheit.RatioExamples: temperature in Kelvin, length, time, counts
Properties of Attribute Values The type of an attribute depends on which of the following properties it possesses:Distinctness: = Order: < > Addition: + - Multiplication: * /
Nominal attribute: distinctnessOrdinal attribute: distinctness & orderInterval attribute: distinctness, order & additionRatio attribute: all 4 properties
Attribute Type
Description
Examples
Operations
Nominal
The values of a nominal attribute are just different names, i.e., nominal attributes provide only enough information to distinguish one object from another. (=, )
zip codes, employee ID numbers, eye color, sex: {male, female}
mode, entropy, contingency correlation, 2 test
Ordinal
The values of an ordinal attribute provide enough information to order objects. (<, >)
hardness of minerals, {good, better, best},
grades, street numbers
median, percentiles, rank correlation, run tests, sign tests
Interval
For interval attributes, the differences between values are meaningful, i.e., a unit of measurement exists.
(+, - )
calendar dates, temperature in Celsius or Fahrenheit
mean, standard deviation, Pearson's correlation, t and F tests
Ratio
For ratio variables, both differences and ratios are meaningful. (*, /)
temperature in Kelvin, monetary quantities, counts, age, mass, length, electrical current
geometric mean, harmonic mean, percent variation
Attribute Level
Transformation
Comments
Nominal
Any permutation of values
If all employee ID numbers were reassigned, would it make any difference?
Ordinal
An .
This presenations provides an outlook of what we anticipate with the structured data hub: to create linkable datasets, enhance the use of provenance, add quality flags to data, answer new questions and finally, borrow from and provide to public sources such as dbpedia
Model Attribute Check Company Auto PropertyCeline George
In Odoo, the multi-company feature allows you to manage multiple companies within a single Odoo database instance. Each company can have its own configurations while still sharing common resources such as products, customers, and suppliers.
A review of the growth of the Israel Genealogy Research Association Database Collection for the last 12 months. Our collection is now passed the 3 million mark and still growing. See which archives have contributed the most. See the different types of records we have, and which years have had records added. You can also see what we have for the future.
Introduction to AI for Nonprofits with Tapp NetworkTechSoup
Dive into the world of AI! Experts Jon Hill and Tareq Monaur will guide you through AI's role in enhancing nonprofit websites and basic marketing strategies, making it easy to understand and apply.
Read| The latest issue of The Challenger is here! We are thrilled to announce that our school paper has qualified for the NATIONAL SCHOOLS PRESS CONFERENCE (NSPC) 2024. Thank you for your unwavering support and trust. Dive into the stories that made us stand out!
Biological screening of herbal drugs: Introduction and Need for
Phyto-Pharmacological Screening, New Strategies for evaluating
Natural Products, In vitro evaluation techniques for Antioxidants, Antimicrobial and Anticancer drugs. In vivo evaluation techniques
for Anti-inflammatory, Antiulcer, Anticancer, Wound healing, Antidiabetic, Hepatoprotective, Cardio protective, Diuretics and
Antifertility, Toxicity studies as per OECD guidelines
Exploiting Artificial Intelligence for Empowering Researchers and Faculty, In...Dr. Vinod Kumar Kanvaria
Exploiting Artificial Intelligence for Empowering Researchers and Faculty,
International FDP on Fundamentals of Research in Social Sciences
at Integral University, Lucknow, 06.06.2024
By Dr. Vinod Kumar Kanvaria
2. Statistical Science
Descriptive statistics
– Collecting, presenting, and describing
data
Inferential statistics
– Drawing conclusions and/or making
decisions concerning a population based
only on sample data
3. Descriptive Statistics
Collect data
e.g., Survey, Observation, Experiments
Present data
e.g., Charts and graphs
Characterize data
e.g., Sample mean
n
xi
6. Data Types
Time Series Data
– Ordered data values observed over time.
Cross Section Data
– Data values observed at a fxed point in time.
7. Data Types
Sales (in £1000’s)
2013 2014 2015 2016
London 435 460 475 490
York 320 345 375 395
Bristol 405 390 410 395
Kent 260 270 285 280
Time
Series
Data
Cross
Section
Data
8. Data Measurement Levels
Ratio/Interval Data
Ordinal Data
Nominal Data
Highest Level
Complete Analysis
Higher Level
Mid-level Analysis
Lowest Level
Basic Analysis
Categorical Codes ID
Numbers Category
Names
Rankings
Ordered Categories
Measurements
11. Nominal scalesNominal scales
A nominal scale of measurement only indicates the
category of a variable that a case falls into: it expresses
qualitative diferences but not quantitative diferences, and
as such data at this level are often referred to as qualitative
data.
A nominal scale only allows us to say that one case may be
diferent from another
No ‘natural’ order to the arrangement of categories
Often identifed by ‘Other’ category
12. Ordinal scalesOrdinal scales
Consider that we operationalise age so that we measure its
variation by recording whether someone is:
young (18 years or less),
middle aged (19-60 years), or
old (over 60 years)
We can say one case may be diferent to another in terms of
age, and
We can say one case may have more or less age than another,
but
We cannot say how much more age one case may have as
compared to another
13. Ordinal scales (cont.)Ordinal scales (cont.)
An ordinal level of measurement, in addition to the function
of classifcation, allows cases to be ordered by degree
according to measurements of the variable.
But we cannot quantify the amount of diference – there is
no unit of measurement like years or dollars.
Ordinal scales are particularly common when measuring
attitude or satisfaction in opinion surveys.
Yes/No responses are often ordinal e.g. “Do you enjoy
statistics (Yes/No)?”
we can say that someone who answers ‘Yes’ has more enjoyment of
statistics than someone who responds ‘No’, but
we can’t say how much more enjoyment of statistics they have.
14. Interval/ratio scalesInterval/ratio scales
The key characteristic of an interval/ratio scale is that it has
units measuring intervals of equal distance between values
on the scale.
Consider the variable ‘age’. This can be defned
operationally as ‘age in whole years at last birthday’.
Having defned age this way our measurements of people’s
age will allow us to say:
one case may be diferent to another in terms of age, and
one case may have more or less age than another, and
how much more age one case may have as compared to another.
15. Types of Data
In all scientifc disciplines,
we are obliged to
understand the Stevens’
data classifcation...
17. Although Steven's taxonomy
has permeated all scientifc
disciplines, we still need to
characterize data to match the
way the digital computers work.
18. When we look at many variables, some may
simply record categories used to group the
data.
In R we will use factors to store these
variables.
An example might be the browser a user has
used to view a web site, as gleaned from a web
site log.
factor datafactor data
19. Some categorical data are factors, but others
are really just identifers, and are not used for
grouping.
An example might be a user’s IP address. This is
basically a unique code identifying a computer,
like an address.
While both factor and categorical data are
“nominal” we keep the distinction as we will
interact with such data in R diferently.
character datacharacter data
20. Discrete data comes from measurements
where there are essentially only distinct
and separate possible values that can be
counted.
For example, the number of visits a person
makes to our web site will always be
integer data, as will other counting data.
discrete datadiscrete data
21. Continuous data is that which could conceivably
come from a continuum of values.
The recording of the time in milliseconds of a visit
to a web site might be such data.
A useful distinction is that for discrete data we
expect that cases will share values, whereas for
continuous data this will be impossible, or at least
very unlikely.
There is no fne line though.
continuous datacontinuous data
22. Time data can be considered continuous or discrete
depending on resolution, for computers there are often
separate ways entirely to handle date and time data.
People in fnance want millisecond data, but over long
time ranges this recording can literally run out of
numbers on a computer.
Astronomers need precise measurements for durations
down to leap seconds.
R has several ways to work with such data, that go
beyond just storing the values as simple numbers.
date and time datadate and time data
24. To organise data, R assigns a class
attribute to most R objects and otherwise
creates an implicit class for an object.
The class of an object is used to determine
how it should be printed.
The class function will return the class of
an object.
25. The two main classes for numeric data are numeric and
integer, though there are others, e.g. complex. Most of the
time numbers are numeric.
To make an integer value, we need to work a bit: we can
preallocate space for an integer data set of length n with
integer(n); we can use the sufx L to force a number to be
treated as an integer (e.g., 1L); we can coerce numeric values
of integer type through the as.integer function.
Numeric values are stored using foating point representation.
This format can store much larger integer values and has a
much wider range of numbers it can represent.
Numeric data typesNumeric data types
26. Character data. Character data is created
just by quoting values.
Quotes can be matching pairs of single or
double quotes, though double quotes are
preferred and used to display character
values.
Within a quoted value a quote symbol can be
used, but it must be escaped by prefxing it
with a backslash.
Categorical data typesCategorical data types
27. Factors. A factor can be made from a character
vector with the factor function.
The levels of a factor are a list of all possible
categories for the data in the factor.
They need not all be represented in a particular factor,
but when we create a factor through factor the default
choice is simply the collection of unique values.
The current levels of a factor are returned by the
levels function.
Categorical data typesCategorical data types
28. Working with dates and times is made more
convenient using a special data type.
While R has some built-in features to work with
dates and times, the lubridate package simplifes
the usage.
This package introduces the notion of “instants,”
“durations,” and “intervals” of time.
We concern ourselves with some basics, learning
how to make and manipulate instants of time.
Date and time typesDate and time types
29. R uses TRUE and FALSE to represent Boolean or logical data.
Logical data is produced by many R functions, for example the
“is” functions.
Most common, is the use of the comparison operators—<, <=,
==, !=, >=, > — to produce logical values.
The operators ! (for not), & (for and), and | (for or) can be used
to combine values.
The functions any, all, which, and %in% are useful functions for
working with logical vectors. The any and all functions answer
whether any of the values are TRUE or if all the values are true.
Logical dataLogical data