--- title: "Vignette For ggplotcli" author: "Claas Heuer" date: "`r Sys.Date()`" output: rmarkdown::html_vignette vignette: > %\VignetteIndexEntry{Introduction to ggplotcli} %\VignetteEngine{knitr::rmarkdown} %\VignetteEncoding{UTF-8} --- ```{r setup, include = FALSE} knitr::opts_chunk$set( collapse = TRUE, comment = "#>" ) ``` ## Using `ggplotcli` with `ggplot2` ```{r} library(plotcli) mtcars$cf = as.character(mtcars$cyl) mtcars_ggplot <- ggplot(mtcars, aes(x = mpg, y = wt)) + geom_point() + geom_smooth(method = "lm", color = "red") + labs(title = "Mtcars Dataset with Regression Line", x = "Miles per Gallon", y = "Weight") pp = ggplotcli(mtcars_ggplot, braille = FALSE) pp$print_plot() ```