Replies: 2 comments
-
Try patchwork. See TidyX, Episode 50 for an example.
https://www.youtube.com/watch?v=1WtDWE0UbQg
On Thu, May 19, 2022, at 19:05, markm0705 wrote:
How do I combine a gt table with a chart from ggplot()?
I have a chart saved as p1 and a gt table as p2.
When I attempt to combine both using cowplot to a object to save 'p3 <- plot_grid(p1, p2, nrow = 2, rel_widths = c(1,1)) '
... I get this error
... 3: In as_grob.default(plot) :
Cannot convert object of class gt_tbllist into a grob.
Nice method of making tables but not much use if I can't combine it with other plots. Note: using cowpolt's as_grob() function does not help ... it suppresses the error but I get no table on the combined plot
—
Reply to this email directly, view it on GitHub <#945>, or unsubscribe <https://github.com/notifications/unsubscribe-auth/ALW4MJYZ7UR53AZRD4CKLQLVK3QPNANCNFSM5WN4PAPA>.
You are receiving this because you are subscribed to this thread.Message ID: ***@***.***>
Robert C Cline Sr., MA, CPL
Sidney, NE
***@***.***
|
Beta Was this translation helpful? Give feedback.
0 replies
-
OK thanks for getting back to me ... will give it a try
On Fri, May 20, 2022 at 8:57 PM Robert C Cline, Sr. <
***@***.***> wrote:
… Try patchwork. See TidyX, Episode 50 for an example.
https://www.youtube.com/watch?v=1WtDWE0UbQg
On Thu, May 19, 2022, at 19:05, markm0705 wrote:
>
>
>
> How do I combine a gt table with a chart from ggplot()?
> I have a chart saved as p1 and a gt table as p2.
> When I attempt to combine both using cowplot to a object to save 'p3 <-
plot_grid(p1, p2, nrow = 2, rel_widths = c(1,1)) '
> ... I get this error
> ... 3: In as_grob.default(plot) :
> Cannot convert object of class gt_tbllist into a grob.
>
> Nice method of making tables but not much use if I can't combine it with
other plots. Note: using cowpolt's as_grob() function does not help ... it
suppresses the error but I get no table on the combined plot
>
>
> —
> Reply to this email directly, view it on GitHub <
#945>, or unsubscribe <
https://github.com/notifications/unsubscribe-auth/ALW4MJYZ7UR53AZRD4CKLQLVK3QPNANCNFSM5WN4PAPA
>.
> You are receiving this because you are subscribed to this thread.Message
ID: ***@***.***>
>
Robert C Cline Sr., MA, CPL
Sidney, NE
***@***.***
—
Reply to this email directly, view it on GitHub
<#945 (comment)>,
or unsubscribe
<https://github.com/notifications/unsubscribe-auth/AMQ2IDC24B3EFUDBJE4OOG3VK6D2XANCNFSM5WN4PAPA>
.
You are receiving this because you authored the thread.Message ID:
***@***.***>
--
Mark Murphy
0407 449 543
|
Beta Was this translation helpful? Give feedback.
0 replies
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
-
How do I combine a gt table with a chart from ggplot()?
I have a chart saved as p1 and a gt table as p2.
When I attempt to combine both using cowplot to a object to save 'p3 <- plot_grid(p1, p2, nrow = 2, rel_widths = c(1,1)) '
... I get this error
... 3: In as_grob.default(plot) :
Cannot convert object of class gt_tbllist into a grob.
Nice method of making tables but not much use if I can't combine it with other plots. Note: using cowpolt's as_grob() function does not help ... it suppresses the error but I get no table on the combined plot
Beta Was this translation helpful? Give feedback.
All reactions