Telegram Group & Telegram Channel
Релиз patchwork 1.3.0

Вышла версия patchwork 1.3.0, которая привнесла интересные возможности для работы с таблицами в графических композициях. Теперь можно легко интегрировать таблицы gt с графиками, используя функции wrap_elements() и wrap_table(). Пример простого графика с таблицей:

library(patchwork)
library(ggplot2)
library(gt)

p1 <- ggplot(airquality) +
geom_line(aes(x = Day, y = Temp, colour = month.name[Month])) +
labs(colour = "Month")

aq <- airquality[sample(nrow(airquality), 10), ]
p1 + wrap_table(aq, space = "free_y")


Также доступны более продвинутые возможности для компоновки графиков и таблиц. Например, можно использовать сложный макет с элементами разного размера:

p1 <- ggplot(mtcars) +
geom_point(aes(mpg, disp)) +
ggtitle('Scatter plot')

p2 <- ggplot(mtcars) +
geom_bar(aes(factor(cyl))) +
ggtitle('Bar plot')

layout <- c(
area(t = 1, l = 1, b = 2, r = 2),
area(t = 1, l = 3, b = 2, r = 3)
)

p1 + p2 + plot_layout(design = layout)


Это позволяет гибко управлять макетом визуализации, комбинируя таблицы и графики разных типов.

Ссылки:
● Подробнее можно прочитать в оригинальной статье на Tidyverse Blog.
● Также ранее я уже рассказывал о пакете patchwork в посте "Как расположить несколько ggplot2 графиков на одном изображении".

#новости_и_релизы_по_R



group-telegram.com/R4marketing/1325
Create:
Last Update:

Релиз patchwork 1.3.0

Вышла версия patchwork 1.3.0, которая привнесла интересные возможности для работы с таблицами в графических композициях. Теперь можно легко интегрировать таблицы gt с графиками, используя функции wrap_elements() и wrap_table(). Пример простого графика с таблицей:

library(patchwork)
library(ggplot2)
library(gt)

p1 <- ggplot(airquality) +
geom_line(aes(x = Day, y = Temp, colour = month.name[Month])) +
labs(colour = "Month")

aq <- airquality[sample(nrow(airquality), 10), ]
p1 + wrap_table(aq, space = "free_y")


Также доступны более продвинутые возможности для компоновки графиков и таблиц. Например, можно использовать сложный макет с элементами разного размера:

p1 <- ggplot(mtcars) +
geom_point(aes(mpg, disp)) +
ggtitle('Scatter plot')

p2 <- ggplot(mtcars) +
geom_bar(aes(factor(cyl))) +
ggtitle('Bar plot')

layout <- c(
area(t = 1, l = 1, b = 2, r = 2),
area(t = 1, l = 3, b = 2, r = 3)
)

p1 + p2 + plot_layout(design = layout)


Это позволяет гибко управлять макетом визуализации, комбинируя таблицы и графики разных типов.

Ссылки:
● Подробнее можно прочитать в оригинальной статье на Tidyverse Blog.
● Также ранее я уже рассказывал о пакете patchwork в посте "Как расположить несколько ggplot2 графиков на одном изображении".

#новости_и_релизы_по_R

BY R4marketing | канал Алексея Селезнёва | Язык R




Share with your friend now:
group-telegram.com/R4marketing/1325

View MORE
Open in Telegram


Telegram | DID YOU KNOW?

Date: |

The original Telegram channel has expanded into a web of accounts for different locations, including specific pages made for individual Russian cities. There's also an English-language website, which states it is owned by the people who run the Telegram channels. This provided opportunity to their linked entities to offload their shares at higher prices and make significant profits at the cost of unsuspecting retail investors. Sebi said data, emails and other documents are being retrieved from the seized devices and detailed investigation is in progress. Telegram has gained a reputation as the “secure” communications app in the post-Soviet states, but whenever you make choices about your digital security, it’s important to start by asking yourself, “What exactly am I securing? And who am I securing it from?” These questions should inform your decisions about whether you are using the right tool or platform for your digital security needs. Telegram is certainly not the most secure messaging app on the market right now. Its security model requires users to place a great deal of trust in Telegram’s ability to protect user data. For some users, this may be good enough for now. For others, it may be wiser to move to a different platform for certain kinds of high-risk communications. The fake Zelenskiy account reached 20,000 followers on Telegram before it was shut down, a remedial action that experts say is all too rare.
from us


Telegram R4marketing | канал Алексея Селезнёва | Язык R
FROM American