SlideShare a Scribd company logo
www.r-squared.in/git-hub
dataCrunch Data Visualization With R
Learn To Modify Font Of Graphical Parameters
dataCrunch
Font
Slide 2
dataCrunchFont
Slide 3
The font argument can be used along with main, sub, axis and lab arguments to specify the font of
the title, subtitle, axes and the labels.
Feature Argument
Title font.main
Subtitle font.sub
Axis font.axis
Labels font.lab
The font argument takes values from 1 - 5. The font type represented by each value is shown in the
above table.
Value Font Type
1 Plain
2 Bold
3 Italic
4 Bold Italic
5 Symbol
dataCrunchFont: Title
Slide 4
# modify the font of the title
plot(mtcars$disp, mtcars$mpg,
main = "Displacement vs Miles Per Gallon",
font.main = 1)
Description
The font of the title can be modified using the font.
main argument in the plot() function.
Code
dataCrunchFont: Title
Slide 5
The below plot depicts the appearance of the title when different options for font type are applied:
dataCrunchFont: Subtitle
Slide 6
# modify the font of the subtitle
plot(mtcars$disp, mtcars$mpg,
sub= "Displacement vs Miles Per Gallon",
font.sub = 3)
Description
The font of the subtitle can be modified using the
font.sub argument in the plot() function.
Code
dataCrunchFont: Subtitle
Slide 7
The below plot depicts the appearance of the subtitle when different options for font type are applied:
dataCrunchFont: Axis
Slide 8
# modify the font of the axis
plot(mtcars$disp, mtcars$mpg,
font.axis = 3)
Description
The font of the axis can be modified using the
font.axis argument in the plot() function.
Code
dataCrunchFont: Axis
Slide 9
The below plot depicts the appearance of the axis when different options for font type are applied:
dataCrunchFont: Labels
Slide 10
# modify the font of the labels
plot(mtcars$disp, mtcars$mpg,
xlab = "Displacement",
ylab = "Miles Per Gallon",
font.lab = 3)
Description
The font of the labels can be modified using the
font.lab argument in the plot() function.
Code
dataCrunchFont: Labels
Slide 11
The below plot depicts the appearance of the labels when different options for font type are applied:
dataCrunch
Font Size
Slide 12
dataCrunchFont Size
Slide 13
The cex argument can be used along with main, sub, axis and lab arguments to specify the font size
of the title, subtitle, axes and the labels.
Feature Argument
Title cex.main
Subtitle cex.sub
Axis cex.axis
Labels cex.lab
The values taken by the cex argument are relative to 1 i.e the default size is represented by 1 and if
the supplied value is less than 1, the size of the font will be relatively smaller, and if the supplied value
is greater than 1, the size of the font will be relatively bigger.
dataCrunchFont Size: Title
Slide 14
# modify the font size of the title
plot(mtcars$disp, mtcars$mpg,
main = "Scatter Plot",
cex.main = 1.5)
Description
The font size of the title can be modified using the
cex.main argument in the plot() function.
Code
dataCrunchFont Size: Title
Slide 15
The below plot depicts the appearance of the title when different options for font size are applied:
dataCrunchFont Size: Subtitle
Slide 16
# modify the font size of the subtitle
plot(mtcars$disp, mtcars$mpg,
sub= "Scatter Plot",
cex.sub = 1.5)
Description
The font size of the subtitle can be modified using
the cex.sub argument in the plot() function.
Code
dataCrunchFont: Subtitle
Slide 17
The below plot depicts the appearance of the subtitle when different options for font size are applied:
dataCrunchFont Size: Axis
Slide 18
# modify the font size of the axis
plot(mtcars$disp, mtcars$mpg,
cex.axis = 1.5)
Description
The font size of the axis can be modified using the
cex.axis argument in the plot() function.
Code
dataCrunchFont Size: Axis
Slide 19
The below plot depicts the appearance of the axis when different options for font size are applied:
dataCrunchFont Size: Labels
Slide 20
# modify the font size of the labels
plot(mtcars$disp, mtcars$mpg,
xlab = "Displacement",
ylab = "Miles Per Gallon",
cex.lab = 1.5)
Description
The font size of the labels can be modified using the
cex.lab argument in the plot() function.
Code
dataCrunchFont Size: Labels
Slide 21
The below plot depicts the appearance of the subtitle when different options for font size are applied:
dataCrunch
Slide 22
Visit dataCrunch for
tutorials on:
→ R Programming
→ Business Analytics
→ Data Visualization
→ Web Applications
→ Package Development
→ Git & GitHub
Ad

Recommended

R Data Visualization: Learn To Add Text Annotations To Plots
R Data Visualization: Learn To Add Text Annotations To Plots
Rsquared Academy
 
Data Visualization With R: Learn To Modify Color Of Plots
Data Visualization With R: Learn To Modify Color Of Plots
Rsquared Academy
 
R Data Visualization Tutorial: Bar Plots
R Data Visualization Tutorial: Bar Plots
Rsquared Academy
 
Data Visualization With R: Introduction
Data Visualization With R: Introduction
Rsquared Academy
 
Data Visualization With R: Learn To Combine Multiple Graphs
Data Visualization With R: Learn To Combine Multiple Graphs
Rsquared Academy
 
Data Visualization With R: Learn To Modify Title, Axis Labels & Range
Data Visualization With R: Learn To Modify Title, Axis Labels & Range
Rsquared Academy
 
Data Visualization With R
Data Visualization With R
Rsquared Academy
 
NCCU: Statistics in the Criminal Justice System, R basics and Simulation - Pr...
NCCU: Statistics in the Criminal Justice System, R basics and Simulation - Pr...
The Statistical and Applied Mathematical Sciences Institute
 
Access intermediate 2010 final project new
Access intermediate 2010 final project new
clscott1
 
R Programming: Numeric Functions In R
R Programming: Numeric Functions In R
Rsquared Academy
 
An introduction to matlab
An introduction to matlab
Dr. Andrew Wallace PhD
 
Chapter13 two-dimensional-array
Chapter13 two-dimensional-array
Deepak Singh
 
Extreme querying with_analytics
Extreme querying with_analytics
Gary Myers
 
R studio
R studio
Kinza Irshad
 
Excel/R
Excel/R
Andrija Djurovic
 
statistical computation using R- an intro..
statistical computation using R- an intro..
Kamarudheen KV
 
Lecture 1 mte 407
Lecture 1 mte 407
rumanatasnim415
 
Lecture 1 mte 407
Lecture 1 mte 407
rumanatasnim415
 
R-Excel Integration
R-Excel Integration
Andrija Djurovic
 
Introduction to matlab
Introduction to matlab
Sourabh Bhattacharya
 
Doc 20180130-wa0004
Doc 20180130-wa0004
HarithaRanasinghe
 
Assignment3
Assignment3
Mahmoud
 
Assigment 3
Assigment 3
sukumaraser
 
Conversion from infix to prefix using stack
Conversion from infix to prefix using stack
Haqnawaz Ch
 
The matplotlib Library
The matplotlib Library
Haim Michael
 
Day 2 examples u6w14
Day 2 examples u6w14
jchartiersjsd
 
Lecture_3.pptx
Lecture_3.pptx
SungaleliYuen
 
Sterling Integrator Map Editor
Sterling Integrator Map Editor
Jeyhind M
 
2GKS, Open GL and IGES_Video Lect Given by Renjin.pptx
2GKS, Open GL and IGES_Video Lect Given by Renjin.pptx
RamanathanSabesan
 
Background This course is all about data visualization. However, we.docx
Background This course is all about data visualization. However, we.docx
rosemaryralphs52525
 

More Related Content

What's hot (18)

Access intermediate 2010 final project new
Access intermediate 2010 final project new
clscott1
 
R Programming: Numeric Functions In R
R Programming: Numeric Functions In R
Rsquared Academy
 
An introduction to matlab
An introduction to matlab
Dr. Andrew Wallace PhD
 
Chapter13 two-dimensional-array
Chapter13 two-dimensional-array
Deepak Singh
 
Extreme querying with_analytics
Extreme querying with_analytics
Gary Myers
 
R studio
R studio
Kinza Irshad
 
Excel/R
Excel/R
Andrija Djurovic
 
statistical computation using R- an intro..
statistical computation using R- an intro..
Kamarudheen KV
 
Lecture 1 mte 407
Lecture 1 mte 407
rumanatasnim415
 
Lecture 1 mte 407
Lecture 1 mte 407
rumanatasnim415
 
R-Excel Integration
R-Excel Integration
Andrija Djurovic
 
Introduction to matlab
Introduction to matlab
Sourabh Bhattacharya
 
Doc 20180130-wa0004
Doc 20180130-wa0004
HarithaRanasinghe
 
Assignment3
Assignment3
Mahmoud
 
Assigment 3
Assigment 3
sukumaraser
 
Conversion from infix to prefix using stack
Conversion from infix to prefix using stack
Haqnawaz Ch
 
The matplotlib Library
The matplotlib Library
Haim Michael
 
Day 2 examples u6w14
Day 2 examples u6w14
jchartiersjsd
 
Access intermediate 2010 final project new
Access intermediate 2010 final project new
clscott1
 
R Programming: Numeric Functions In R
R Programming: Numeric Functions In R
Rsquared Academy
 
Chapter13 two-dimensional-array
Chapter13 two-dimensional-array
Deepak Singh
 
Extreme querying with_analytics
Extreme querying with_analytics
Gary Myers
 
statistical computation using R- an intro..
statistical computation using R- an intro..
Kamarudheen KV
 
Assignment3
Assignment3
Mahmoud
 
Conversion from infix to prefix using stack
Conversion from infix to prefix using stack
Haqnawaz Ch
 
The matplotlib Library
The matplotlib Library
Haim Michael
 
Day 2 examples u6w14
Day 2 examples u6w14
jchartiersjsd
 

Similar to Data Visualization With R: Learn To Modify Font Of Graphical Parameters (20)

Lecture_3.pptx
Lecture_3.pptx
SungaleliYuen
 
Sterling Integrator Map Editor
Sterling Integrator Map Editor
Jeyhind M
 
2GKS, Open GL and IGES_Video Lect Given by Renjin.pptx
2GKS, Open GL and IGES_Video Lect Given by Renjin.pptx
RamanathanSabesan
 
Background This course is all about data visualization. However, we.docx
Background This course is all about data visualization. However, we.docx
rosemaryralphs52525
 
Abap programming overview
Abap programming overview
k kartheek
 
Introduction to r
Introduction to r
Golden Julie Jesus
 
charts
charts
pipalmetto
 
M2M_250327_22434hjjik7_250411_183538.pdf
M2M_250327_22434hjjik7_250411_183538.pdf
HebaEng
 
Computation Assignment Help
Computation Assignment Help
Programming Homework Help
 
Ppt lesson 07
Ppt lesson 07
Linda Bodrie
 
Introduction to matlab
Introduction to matlab
Sourabh Bhattacharya
 
2013-June: 7th Semester CSE Question Papers
2013-June: 7th Semester CSE Question Papers
B G S Institute of Technolgy
 
7th Semester Computer Science (2013-June) Question Papers
7th Semester Computer Science (2013-June) Question Papers
BGS Institute of Technology, Adichunchanagiri University (ACU)
 
7th cs june 2013
7th cs june 2013
BGS Institute of Technology, Adichunchanagiri University (ACU)
 
Here is The code in C language .pdf
Here is The code in C language .pdf
geetakannupillai1
 
ABAP Programming Overview
ABAP Programming Overview
sapdocs. info
 
chapter-1abapprogrammingoverview-091205081953-phpapp01
chapter-1abapprogrammingoverview-091205081953-phpapp01
tabish
 
Chapter 1 Abap Programming Overview
Chapter 1 Abap Programming Overview
Ashish Kumar
 
Abapprogrammingoverview 090715081305-phpapp02
Abapprogrammingoverview 090715081305-phpapp02
tabish
 
Abapprogrammingoverview 090715081305-phpapp02
Abapprogrammingoverview 090715081305-phpapp02
wingsrai
 
Sterling Integrator Map Editor
Sterling Integrator Map Editor
Jeyhind M
 
2GKS, Open GL and IGES_Video Lect Given by Renjin.pptx
2GKS, Open GL and IGES_Video Lect Given by Renjin.pptx
RamanathanSabesan
 
Background This course is all about data visualization. However, we.docx
Background This course is all about data visualization. However, we.docx
rosemaryralphs52525
 
Abap programming overview
Abap programming overview
k kartheek
 
M2M_250327_22434hjjik7_250411_183538.pdf
M2M_250327_22434hjjik7_250411_183538.pdf
HebaEng
 
Here is The code in C language .pdf
Here is The code in C language .pdf
geetakannupillai1
 
ABAP Programming Overview
ABAP Programming Overview
sapdocs. info
 
chapter-1abapprogrammingoverview-091205081953-phpapp01
chapter-1abapprogrammingoverview-091205081953-phpapp01
tabish
 
Chapter 1 Abap Programming Overview
Chapter 1 Abap Programming Overview
Ashish Kumar
 
Abapprogrammingoverview 090715081305-phpapp02
Abapprogrammingoverview 090715081305-phpapp02
tabish
 
Abapprogrammingoverview 090715081305-phpapp02
Abapprogrammingoverview 090715081305-phpapp02
wingsrai
 
Ad

More from Rsquared Academy (20)

Handling Date & Time in R
Handling Date & Time in R
Rsquared Academy
 
Market Basket Analysis in R
Market Basket Analysis in R
Rsquared Academy
 
Practical Introduction to Web scraping using R
Practical Introduction to Web scraping using R
Rsquared Academy
 
Joining Data with dplyr
Joining Data with dplyr
Rsquared Academy
 
Explore Data using dplyr
Explore Data using dplyr
Rsquared Academy
 
Data Wrangling with dplyr
Data Wrangling with dplyr
Rsquared Academy
 
Writing Readable Code with Pipes
Writing Readable Code with Pipes
Rsquared Academy
 
Introduction to tibbles
Introduction to tibbles
Rsquared Academy
 
Read data from Excel spreadsheets into R
Read data from Excel spreadsheets into R
Rsquared Academy
 
Read/Import data from flat/delimited files into R
Read/Import data from flat/delimited files into R
Rsquared Academy
 
Variables & Data Types in R
Variables & Data Types in R
Rsquared Academy
 
How to install & update R packages?
How to install & update R packages?
Rsquared Academy
 
How to get help in R?
How to get help in R?
Rsquared Academy
 
Introduction to R
Introduction to R
Rsquared Academy
 
RMySQL Tutorial For Beginners
RMySQL Tutorial For Beginners
Rsquared Academy
 
R Markdown Tutorial For Beginners
R Markdown Tutorial For Beginners
Rsquared Academy
 
R Programming: Introduction to Matrices
R Programming: Introduction to Matrices
Rsquared Academy
 
R Programming: Introduction to Vectors
R Programming: Introduction to Vectors
Rsquared Academy
 
R Programming: Variables & Data Types
R Programming: Variables & Data Types
Rsquared Academy
 
R Programming: Mathematical Functions In R
R Programming: Mathematical Functions In R
Rsquared Academy
 
Market Basket Analysis in R
Market Basket Analysis in R
Rsquared Academy
 
Practical Introduction to Web scraping using R
Practical Introduction to Web scraping using R
Rsquared Academy
 
Writing Readable Code with Pipes
Writing Readable Code with Pipes
Rsquared Academy
 
Read data from Excel spreadsheets into R
Read data from Excel spreadsheets into R
Rsquared Academy
 
Read/Import data from flat/delimited files into R
Read/Import data from flat/delimited files into R
Rsquared Academy
 
Variables & Data Types in R
Variables & Data Types in R
Rsquared Academy
 
How to install & update R packages?
How to install & update R packages?
Rsquared Academy
 
RMySQL Tutorial For Beginners
RMySQL Tutorial For Beginners
Rsquared Academy
 
R Markdown Tutorial For Beginners
R Markdown Tutorial For Beginners
Rsquared Academy
 
R Programming: Introduction to Matrices
R Programming: Introduction to Matrices
Rsquared Academy
 
R Programming: Introduction to Vectors
R Programming: Introduction to Vectors
Rsquared Academy
 
R Programming: Variables & Data Types
R Programming: Variables & Data Types
Rsquared Academy
 
R Programming: Mathematical Functions In R
R Programming: Mathematical Functions In R
Rsquared Academy
 
Ad

Recently uploaded (20)

NVIDIA Triton Inference Server, a game-changing platform for deploying AI mod...
NVIDIA Triton Inference Server, a game-changing platform for deploying AI mod...
Tamanna36
 
Reliability Monitoring of Aircrfat commerce
Reliability Monitoring of Aircrfat commerce
Rizk2
 
Indigo dyeing Presentation (2).pptx as dye
Indigo dyeing Presentation (2).pptx as dye
shreeroop1335
 
Crafting-Research-Recommendations Grade 12.pptx
Crafting-Research-Recommendations Grade 12.pptx
DaryllWhere
 
最新版美国佐治亚大学毕业证(UGA毕业证书)原版定制
最新版美国佐治亚大学毕业证(UGA毕业证书)原版定制
Taqyea
 
Daily, Weekly, Monthly Report MTC March 2025.pptx
Daily, Weekly, Monthly Report MTC March 2025.pptx
PanjiDewaPamungkas1
 
All the DataOps, all the paradigms .
All the DataOps, all the paradigms .
Lars Albertsson
 
最新版美国约翰霍普金斯大学毕业证(JHU毕业证书)原版定制
最新版美国约翰霍普金斯大学毕业证(JHU毕业证书)原版定制
Taqyea
 
Model Evaluation & Visualisation part of a series of intro modules for data ...
Model Evaluation & Visualisation part of a series of intro modules for data ...
brandonlee626749
 
英国毕业证范本利物浦约翰摩尔斯大学成绩单底纹防伪LJMU学生证办理学历认证
英国毕业证范本利物浦约翰摩尔斯大学成绩单底纹防伪LJMU学生证办理学历认证
taqyed
 
@Reset-Password.pptx presentakh;kenvtion
@Reset-Password.pptx presentakh;kenvtion
MarkLariosa1
 
PPT1_CB_VII_CS_Ch3_FunctionsandChartsinCalc.ppsx
PPT1_CB_VII_CS_Ch3_FunctionsandChartsinCalc.ppsx
animaroy81
 
Indigo_Airlines_Strategy_Presentation.pptx
Indigo_Airlines_Strategy_Presentation.pptx
mukeshpurohit991
 
Communication_Skills_Class10_Visual.pptx
Communication_Skills_Class10_Visual.pptx
namanrastogi70555
 
定制OCAD学生卡加拿大安大略艺术与设计大学成绩单范本,OCAD成绩单复刻
定制OCAD学生卡加拿大安大略艺术与设计大学成绩单范本,OCAD成绩单复刻
taqyed
 
最新版美国威斯康星大学河城分校毕业证(UWRF毕业证书)原版定制
最新版美国威斯康星大学河城分校毕业证(UWRF毕业证书)原版定制
taqyea
 
最新版意大利米兰大学毕业证(UNIMI毕业证书)原版定制
最新版意大利米兰大学毕业证(UNIMI毕业证书)原版定制
taqyea
 
Mynd company all details what they are doing a
Mynd company all details what they are doing a
AniketKadam40952
 
ilide.info-tg-understanding-culture-society-and-politics-pr_127f984d2904c57ec...
ilide.info-tg-understanding-culture-society-and-politics-pr_127f984d2904c57ec...
jed P
 
Measurecamp Copenhagen - Consent Context
Measurecamp Copenhagen - Consent Context
Human37
 
NVIDIA Triton Inference Server, a game-changing platform for deploying AI mod...
NVIDIA Triton Inference Server, a game-changing platform for deploying AI mod...
Tamanna36
 
Reliability Monitoring of Aircrfat commerce
Reliability Monitoring of Aircrfat commerce
Rizk2
 
Indigo dyeing Presentation (2).pptx as dye
Indigo dyeing Presentation (2).pptx as dye
shreeroop1335
 
Crafting-Research-Recommendations Grade 12.pptx
Crafting-Research-Recommendations Grade 12.pptx
DaryllWhere
 
最新版美国佐治亚大学毕业证(UGA毕业证书)原版定制
最新版美国佐治亚大学毕业证(UGA毕业证书)原版定制
Taqyea
 
Daily, Weekly, Monthly Report MTC March 2025.pptx
Daily, Weekly, Monthly Report MTC March 2025.pptx
PanjiDewaPamungkas1
 
All the DataOps, all the paradigms .
All the DataOps, all the paradigms .
Lars Albertsson
 
最新版美国约翰霍普金斯大学毕业证(JHU毕业证书)原版定制
最新版美国约翰霍普金斯大学毕业证(JHU毕业证书)原版定制
Taqyea
 
Model Evaluation & Visualisation part of a series of intro modules for data ...
Model Evaluation & Visualisation part of a series of intro modules for data ...
brandonlee626749
 
英国毕业证范本利物浦约翰摩尔斯大学成绩单底纹防伪LJMU学生证办理学历认证
英国毕业证范本利物浦约翰摩尔斯大学成绩单底纹防伪LJMU学生证办理学历认证
taqyed
 
@Reset-Password.pptx presentakh;kenvtion
@Reset-Password.pptx presentakh;kenvtion
MarkLariosa1
 
PPT1_CB_VII_CS_Ch3_FunctionsandChartsinCalc.ppsx
PPT1_CB_VII_CS_Ch3_FunctionsandChartsinCalc.ppsx
animaroy81
 
Indigo_Airlines_Strategy_Presentation.pptx
Indigo_Airlines_Strategy_Presentation.pptx
mukeshpurohit991
 
Communication_Skills_Class10_Visual.pptx
Communication_Skills_Class10_Visual.pptx
namanrastogi70555
 
定制OCAD学生卡加拿大安大略艺术与设计大学成绩单范本,OCAD成绩单复刻
定制OCAD学生卡加拿大安大略艺术与设计大学成绩单范本,OCAD成绩单复刻
taqyed
 
最新版美国威斯康星大学河城分校毕业证(UWRF毕业证书)原版定制
最新版美国威斯康星大学河城分校毕业证(UWRF毕业证书)原版定制
taqyea
 
最新版意大利米兰大学毕业证(UNIMI毕业证书)原版定制
最新版意大利米兰大学毕业证(UNIMI毕业证书)原版定制
taqyea
 
Mynd company all details what they are doing a
Mynd company all details what they are doing a
AniketKadam40952
 
ilide.info-tg-understanding-culture-society-and-politics-pr_127f984d2904c57ec...
ilide.info-tg-understanding-culture-society-and-politics-pr_127f984d2904c57ec...
jed P
 
Measurecamp Copenhagen - Consent Context
Measurecamp Copenhagen - Consent Context
Human37
 

Data Visualization With R: Learn To Modify Font Of Graphical Parameters

  • 1. www.r-squared.in/git-hub dataCrunch Data Visualization With R Learn To Modify Font Of Graphical Parameters
  • 3. dataCrunchFont Slide 3 The font argument can be used along with main, sub, axis and lab arguments to specify the font of the title, subtitle, axes and the labels. Feature Argument Title font.main Subtitle font.sub Axis font.axis Labels font.lab The font argument takes values from 1 - 5. The font type represented by each value is shown in the above table. Value Font Type 1 Plain 2 Bold 3 Italic 4 Bold Italic 5 Symbol
  • 4. dataCrunchFont: Title Slide 4 # modify the font of the title plot(mtcars$disp, mtcars$mpg, main = "Displacement vs Miles Per Gallon", font.main = 1) Description The font of the title can be modified using the font. main argument in the plot() function. Code
  • 5. dataCrunchFont: Title Slide 5 The below plot depicts the appearance of the title when different options for font type are applied:
  • 6. dataCrunchFont: Subtitle Slide 6 # modify the font of the subtitle plot(mtcars$disp, mtcars$mpg, sub= "Displacement vs Miles Per Gallon", font.sub = 3) Description The font of the subtitle can be modified using the font.sub argument in the plot() function. Code
  • 7. dataCrunchFont: Subtitle Slide 7 The below plot depicts the appearance of the subtitle when different options for font type are applied:
  • 8. dataCrunchFont: Axis Slide 8 # modify the font of the axis plot(mtcars$disp, mtcars$mpg, font.axis = 3) Description The font of the axis can be modified using the font.axis argument in the plot() function. Code
  • 9. dataCrunchFont: Axis Slide 9 The below plot depicts the appearance of the axis when different options for font type are applied:
  • 10. dataCrunchFont: Labels Slide 10 # modify the font of the labels plot(mtcars$disp, mtcars$mpg, xlab = "Displacement", ylab = "Miles Per Gallon", font.lab = 3) Description The font of the labels can be modified using the font.lab argument in the plot() function. Code
  • 11. dataCrunchFont: Labels Slide 11 The below plot depicts the appearance of the labels when different options for font type are applied:
  • 13. dataCrunchFont Size Slide 13 The cex argument can be used along with main, sub, axis and lab arguments to specify the font size of the title, subtitle, axes and the labels. Feature Argument Title cex.main Subtitle cex.sub Axis cex.axis Labels cex.lab The values taken by the cex argument are relative to 1 i.e the default size is represented by 1 and if the supplied value is less than 1, the size of the font will be relatively smaller, and if the supplied value is greater than 1, the size of the font will be relatively bigger.
  • 14. dataCrunchFont Size: Title Slide 14 # modify the font size of the title plot(mtcars$disp, mtcars$mpg, main = "Scatter Plot", cex.main = 1.5) Description The font size of the title can be modified using the cex.main argument in the plot() function. Code
  • 15. dataCrunchFont Size: Title Slide 15 The below plot depicts the appearance of the title when different options for font size are applied:
  • 16. dataCrunchFont Size: Subtitle Slide 16 # modify the font size of the subtitle plot(mtcars$disp, mtcars$mpg, sub= "Scatter Plot", cex.sub = 1.5) Description The font size of the subtitle can be modified using the cex.sub argument in the plot() function. Code
  • 17. dataCrunchFont: Subtitle Slide 17 The below plot depicts the appearance of the subtitle when different options for font size are applied:
  • 18. dataCrunchFont Size: Axis Slide 18 # modify the font size of the axis plot(mtcars$disp, mtcars$mpg, cex.axis = 1.5) Description The font size of the axis can be modified using the cex.axis argument in the plot() function. Code
  • 19. dataCrunchFont Size: Axis Slide 19 The below plot depicts the appearance of the axis when different options for font size are applied:
  • 20. dataCrunchFont Size: Labels Slide 20 # modify the font size of the labels plot(mtcars$disp, mtcars$mpg, xlab = "Displacement", ylab = "Miles Per Gallon", cex.lab = 1.5) Description The font size of the labels can be modified using the cex.lab argument in the plot() function. Code
  • 21. dataCrunchFont Size: Labels Slide 21 The below plot depicts the appearance of the subtitle when different options for font size are applied:
  • 22. dataCrunch Slide 22 Visit dataCrunch for tutorials on: → R Programming → Business Analytics → Data Visualization → Web Applications → Package Development → Git & GitHub