r - Reuse the output of pander_return in knitr document -


i working on package helps automate exploratory data analysis creating knitr file basic statistics each column of dataframe. 1 issue i've run storing result of pander_return call in function , using output later in knitr document. quick example below of issue in markdown file:

```{r, results='asis', message=false, warning=false}  require(pander)  x <- pander_return(head(cars)) cat(x)  ``` 

i'm having lot of trouble outputting x in readable way. i've tried various forms of cat , print. example, code above produces following output:

1 “————–speed dist ——- ——4 2 4 10 7 4 7 22 8 16 9 10 ————–” attr(,“class”) 1 “knit_asis” attr(,“knit_cacheable”) 1 true

i able see standard output, 1 produced by:

```{r, results='asis', message=false, warning=false}  pander(head(cars))  ``` 

i've attached screen shot well.

screenshot of issue , desired output

thank in advance help


Comments

Popular posts from this blog

php - Wordpress website dashboard page or post editor content is not showing but front end data is showing properly -

javascript - Get parameter of GET request -

javascript - Twitter Bootstrap - how to add some more margin between tooltip popup and element -