R语言画图函数

本文介绍了R语言中用于画图的各种参数设置,包括x(y)axs轴风格、颜色设定、点样式、mfcol/mfrow布局、背景色等。此外,还详细讲解了如par(), col, pch, cex等功能函数的用法,并提到了颜色选择的方法,如heat.colors(), rainbow()等。同时,讨论了如何通过legend()添加图例,以及plot(), density(), lines(), barplot(), hist(), boxplot()等常用绘图函数的应用。" 111778775,10296832,递增复制文字与属性块的LISP程序,"['CAD开发', 'LISP编程', '图形编辑']

摘要生成于 C知道 ,由 DeepSeek-R1 满血版支持, 前往体验 >

  • par()函数

par can be used to set or query graphical parameters. 

x(y)axs

x(y)axs:The style of axis interval calculation to be used for the x(y)-axis. Possible values are "r", "i", "e", "s", "d". The styles are generally controlled by the range of data or x(y)lim, if given.

Style "r" (regular) first extends the data range by 4 percent at each end and then finds an axis with pretty labels that fits within the extended range.

Style "i" (internal) just finds an axis with pretty labels that fits within the original data range.

Style "s" (standard) finds an axis with pretty labels within which the original data range fits.

Style "e" (extended) is like style "s", except that it is also ensures that there is room for plotting symbols within the bounding box.

Style "d" (direct) specifies that the current axis should be used on subsequent plots.

(Only "r" and "i" styles have been implemented in R.)

x(y)asp

A vector of the form c(x1, x2, n) giving the coordinates of the extreme tick marks and the number of intervals between tick-marks when par("x(y)log") is false.

col

A specification for the default plotting color. See section ‘Color Specification’

使用颜色名:col = "颜色名"

使用数值表达颜色:col = n,n为当前调色板上的颜色,

使用十六进制表达颜色 col ="red, green, blue, alpha"

使用col = heat.colors(n)

评论
添加红包

请填写红包祝福语或标题

红包个数最小为10个

红包金额最低5元

当前余额3.43前往充值 >
需支付:10.00
成就一亿技术人!
领取后你会自动成为博主和红包主的粉丝 规则
hope_wisdom
发出的红包
实付
使用余额支付
点击重新获取
扫码支付
钱包余额 0

抵扣说明:

1.余额是钱包充值的虚拟货币,按照1:1的比例进行支付金额的抵扣。
2.余额无法直接购买下载,可以购买VIP、付费专栏及课程。

余额充值