In addition to Weibo, there is also WeChat
Please pay attention
WeChat public account
Shulou
2025-02-22 Update From: SLTechnology News&Howtos shulou NAV: SLTechnology News&Howtos > Internet Technology >
Share
Shulou(Shulou.com)06/02 Report--
This article introduces the relevant knowledge of "introduction of pages and multiple pictures in R language visual chart typesetting". In the operation of actual cases, many people will encounter such a dilemma. Next, let the editor lead you to learn how to deal with these situations! I hope you can read it carefully and be able to achieve something!
Yesterday I shared with you the function usage of chart nesting, and today I share with you how to correctly layout the chart in the case of multiple graphs.
The chart layout design to be shared here actually refers to how to reasonably lay out many charts on a large page after making a lot of pictures, instead of exporting them one by one and finally piecing together manually in other software.
This skill will be especially useful in making multi-map dashboard scenarios:
It should also be emphasized that the multi-page diagram referred to here is quite different from the facet we have introduced before, which is actually a chart that presents the classification chart composed of classification variables. but in essence, a single chart in all facets shares the title, legend, axis scale (although it can be defined manually).
In other words, the type of facet chart is the same as many elements, but facet can not solve the layout problem of different charts: for example, a scatter chart, a column chart and a pie chart drawn separately, facet will be powerless.
There are many functions in R language that can implement the layout of multiple images on the same page (there are about four or five old ones I know), but some parameters are slightly complex and inconvenient to remember. Here are only two:
One is the grid.layout function (that is, the same package used in the chart nesting we talked about yesterday), and the other is the multiplot function in the rmisc package:
Grid.layout function:
Require (ggplot2)
Require (grid)
Draw an alternate chart (the chart must be named here, because the name of the chart needs to be referenced when finally making a summary chart)
Chart1
Welcome to subscribe "Shulou Technology Information " to get latest news, interesting things and hot topics in the IT industry, and controls the hottest and latest Internet news, technology news and IT industry trends.
Views: 0
*The comments in the above article only represent the author's personal views and do not represent the views and positions of this website. If you have more insights, please feel free to contribute and share.
Continue with the installation of the previous hadoop.First, install zookooper1. Decompress zookoope
"Every 5-10 years, there's a rare product, a really special, very unusual product that's the most un
© 2024 shulou.com SLNews company. All rights reserved.