当前位置:网站首页>使用R包skimr汇总统计量的优美展示
使用R包skimr汇总统计量的优美展示
2022-07-29 10:23:00 【Mrrunsen】
数据分析工作的第一步往往是要通过一些描述性的统计,获得对所分析的数据集必要的了解。对于这个任务,在R中有两个常常用到的传统函数,一个是str(),用于展示对象的内部结构,给出数据集中变量的概览;另一个是summary(),给出一些汇总统计量:
library(tidyverse)
str(diamonds)
summary(diamonds)
###结果略
本文要介绍的R包skimr,可以提供变量汇总统计量的更丰富和优美的展示方式。
skimr包的优点:
提供了比summary()更多的统计量,还允许用户添加新的统计量
可以处理更多的数据类型,并按照数据类型报告结果
可以使用knitr进行表格的渲染,且支持基于pillar包的spark_bar和spark_line,输出更美观的结果。
skimr包的核心函数是skim(),它的功能是处理(分组的)数据框,并在可能的情况下将其他类型的对象强制转换为数据框。skim()是作用在数据框的每一列上的,根据每一列(变量)的类型给出相应的统计量:
边栏推荐
- [reading notes] the way of enterprise IT architecture transformation Alibaba's China Taiwan strategic thinking and Architecture Practice
- Attachment of text of chenjie Report
- [HFCTF 2021 Final]easyflask
- JS temporary dead zone_ Temporary
- Knowledge points of common interview questions: distributed lock
- [dark horse morning post] Youxian responded to the dissolution every day, and many places have been unable to place orders; Li Bin said that Wei Lai will produce a mobile phone every year; Li Ka Shing
- Is there any charge for PDF processing? impossible
- Where are those test / development programmers in their 30s? a man should be independent at the age of thirty......
- Docker installation, redis configuration and remote connection
- 全面、详细的SQL学习指南(MySQL方向)
猜你喜欢

MySQL optimization theory study guide

NUMA architecture CPU API change summary

Efficient 7 habit learning notes

Follow teacher Tian to learn practical English Grammar (continuous update)

Why use markdown to write?

PDF处理还收费?不可能

Leetcode question brushing - sorting

How beautiful can VIM be configured?

高效能7个习惯学习笔记

1. (map tools) detailed tutorial of acrgis desktop10.5 software installation
随机推荐
Docker installation, redis configuration and remote connection
[semantic segmentation] 2021-pvt iccv
Talk about multithreaded concurrent programming from a different perspective without heap concept
跟着李老师学线代——行列式(持续更新)
10 suggestions for 10x improvement of application performance
2022cuda summer training camp Day5 practice
静态资源映射
Science fiction style, standard 6 airbags, popular · yachts from 119900
[jetson][reprint]pycharm installed on Jetson
mosquitto_ Sub -f parameter use
[FPGA tutorial case 18] develop low delay open root calculation through ROM
Data office system
What happens when MySQL tables change from compressed tables to ordinary tables
不堆概念、换个角度聊多线程并发编程
可线性渐变的环形进度条的实现探究
二次握手??三次挥手??
Follow teacher Li to learn line generation determinant (continuous update)
皕杰报表之文本附件属件
Drunken driving alarm system based on stm32
English语法_不定代词 - 常用短语