93 Comments
Guest *Tal Galili* @ 2009-11-30 14:34:37 originally posted:
Hi there,
I am trying to contact you but can't seem to find your e-mail.
Please e-mail me at:
tal.galili@gmail.com
Best wishes,
Tal
Hi Tal, you can find my email in my CV or in the bottom of any page. I've read your message and you can post an excerpt (and excerpt only) of my blog article in your website. Thanks!
Originally posted on 2009-12-03 02:48:23
Guest *Indra B. Kshattry* @ 2010-01-09 14:36:59 originally posted:
I couldn't find the function ani.control in animation package. Could you kindly let me know how I can use this function ani.control. You have mentioed this function many times in your viginettes
Thank you
Regards
Indra
That's one of the reasons for why I removed the vignette from the package: some functions have been deprecated. You should use ani.options() for the current version; see the examples for most animation functions.
Originally posted on 2010-01-09 21:28:18
Guest *Indra B. Kshattry* @ 2010-01-09 14:47:47 originally posted:
Excellent Job !!!!
Guest *Indra B. Kshattry* @ 2010-01-15 12:39:21 originally posted:
Hi! Yihui Xie,
Could you kindly send the link of any good (free) download for Latex and the method how to download it.
Regards
Indra
MikTeX should be a good choice for Windows users, and I use TeXLive under Linux. Both are free. If you are very familiar with LaTeX, I would also suggest LyX, which can be regarded as a GUI front-end for LaTeX, but please do not try it before you know enough about LaTeX. I mean do not use Lyx as MS Word.
Originally posted on 2010-01-16 23:13:03
Guest *Ratherbeonatractor* @ 2012-02-18 15:24:42 originally posted:
Can you help me? I have put together several files to create a single file with a three-dimensional array. Now I just want to create some basic plots. My challenge that I am having problems with is this:
I need to graph all of the values in one dimension that have a certain value from another dimension. There are neither dimension titles nor column titles and I'm not sure how to reference my data in order to properly graph it.
The question is not clear to me. You have a 3d array, and your plot description only involves with 2 dimensions. What does the dimension left do?
Originally posted on 2012-02-18 16:23:15
Guest *Ratherbeonatractor* @ 2012-02-18 16:36:06 originally posted:
I make two different plots. Let's say they are dimensions 1, 2, and 3. One plot is x=1 and y = 3. The other is x = 2, y = 3. However, my question is more on indexing. There are no dimension or column titles. Normally I would do something like qplot(filename, x = columnname1, y = columnname2) or something similar. Do I somehow reference the dimension and say if dimension 1 = value, then plot dimension3? Did I make more sense? Thank you!
Say, a is the 3d array, so you want two plots of a[, j, ] and a[i, , ]? They are both matrices; how are you supposed to plot a matrix? There is no way to use a 3d array in ggplot2; in most cases you have to melt() the data to a data frame.
Originally posted on 2012-02-18 16:46:04
Guest *Ratherbeonatractor* @ 2012-02-18 17:03:56 originally posted:
thanks
Guest *Andre* @ 2012-02-18 22:17:07 originally posted:
Hello! I am very impressed by your fantastic job! Well done and thank you for helping the community.
I have difficulties in using lyx and R codes: Particularly, I am using codes from packages installed. Unfortunately, when I run the pdf, lyx shows me the error. ALso R do not read the function (only R-studio does!!!). I would be very happy if you are gonna help me. In case, I can give u my e-mail to have a better communication. Thanks in advance and keep it up!
You need to tell me the error message in detail, and here is a manual that you can read to know how to diagnose problems with LyX and R: https://github.com/downloads/yihui/lyx/sweave.pdf
Originally posted on 2012-02-18 22:34:05
Guest *Andre* @ 2012-02-19 06:28:05 originally posted:
An error occurred while running:
Rscript --verbose --no-save --no-restore
"/Applications/http://LyX.app/Contents/Resources/scripts/lyxsweave.R"
"/var/folders/Pr/Pr7m7EjxGriWcttzRqqei++++TI/-Tmp-/lyx_tmpdir.JL2303/lyx_tmp...
Hope you can have a better idea... Thanks
"An error" is too vague. I can think of ten possible reasons for an error. You need to look further down to figure out what exactly is the error.
Originally posted on 2012-02-19 06:34:55
Guest *Andre* @ 2012-02-19 06:49:12 originally posted:
Yihui... the package has benn downloaded to the folowing:
/var/folders/Pr/Pr7m7EjxGriWcttzRqqei++++TI/-Tmp-//RtmpNOapfu/downloaded_packages. The " error" say a slightly different one.
Is this the problem?
Guest *Murray Logan* @ 2012-03-01 10:09:26 originally posted:
Let me start by congratulating you on knitr. I am a long-time Sweave, cacheSweave, RweaveHTML and pgfSweave user and I really appreciate your efforts to address the few issues with these packages. In preparation for writing the 2nd edition of my book (Biolostatistical Design and Analysis using R), I am considering migrating fully to knitr. The book is published by Wiley and therefore I have a style file that provides a highly customised look etc.
I am having a few issues getting knitr to work neatly with xtable to produce tables. I have tried using the results='asia' or results='tex', yet the tables always seem to end up between knitrout, kframe tags. I have included a snipped below to illustrate.
begin{table}[htbp]caption{Bla Bla Bla}label{tab:BlaBla1} begin{tabularx}{linewidth}{cc} hline A&B hline<<tab1, echo="FALSE," resuls="asis">>=tab <- expand.grid(a=1:4,b=c('A','B'))library(xtable)print(xtable(tab), include.rownames=F,floating=F,only.contents=T,include.colnames=F,sanitize.text.function=function(x) x, sanitize.rownames.function=function(x) x)@ hline end{tabularx}end{table}
The above is a somewhat simplistic example (in that the desired result could just about be obtained by using more arguments to the print.xtable() function. However, it mimics the issue I am having with the modified tabular environment that I must honour for the publisher.
In order for the chunk to play nicely with the tabular environment, it must not itself be within a framed environment.
I have had a look through some of the hooks and they seem to indicate that when results='asis', the result should not be placed within knitrout and kframe environments, yet they clearly are. Is there something obvious I have missed.
Essentially, I want to be able to process a chunk and have it appear without any environments. If this must be done by redefining one or more hooks, I would really appreciate some pointers..
I seems somewhat analogous to the issue with asis plotting and the use of fig.cap etc.
Regards and thanks again
Murray
Hi, I'm glad to know knitr can help you with your book. For the question, yes, the framed package is quite fragile, and this is my headache. I have written a long page to answer your question, but now I decide not to post it because it looks ugly. I will try to find a more elegant solution.
Originally posted on 2012-03-02 07:29:00
Guest *Murray Logan* @ 2012-03-04 22:09:16 originally posted:
Thanks for your reply,
I wonder whether there could be an option to disable the framed environment on a per chunk basis?
BTW, I have also been exploring knitr as a replacement for R2HTML for a series of web-based R workshops (for ecologists) that I maintain. The series covers basic R syntax through to more advanced analyses (although they are very much a work in progress). They also include a workshop on data manipulation with plyr, reshape etc and two on graphics (base and ggplot). I would like to share them with you privately (there are some copyright issues pertaining to my book that I am still to negotiate but means that I cannot release them publicly), as eventually, they could be good examples of the use of knitr (once I sort out the copyright). Is there a direct email address I can reach you on so I can send you the URL?
I have been thinking hard on this issue, and I really want to disable framed when the results involve with special objects like figures and tables. I guess I'm close to a solution. I will let you know later.
You can reach me via xie@yihui.name. Thanks!
Originally posted on 2012-03-04 22:22:02
Hi, I have fixed this issue in the development version: https://github.com/yihui/knitr Now results='asis' should be safe and robust to use. Please let me know if you still have any troubles. Thanks!
Originally posted on 2012-03-06 04:31:57
Guest *isomorphisms* @ 2012-03-23 04:11:03 originally posted:
The design is great. =)
Guest *use-r.com* @ 2012-04-27 01:43:08 originally posted:
Great resources on R! I have added your site link on my R forum. Sweet!
use-r @ http://use-r.com
Guest *Guest* @ 2012-05-15 03:09:48 originally posted:
I am not sure where to take this idea, so I'll leave it here. I do data analysis and write academic papers; mostly I collaborate with Word users, but I use LibreOffice, and use Zotero(zotero.org) to handle bibliographies, research notes, citation formats, etc. Of course, I use R/RStudio for data handling.
But, my workflow is broken up. The knitr/R/Rstudio side doesn't play nicely with the libreoffice/zotero side of things, and what I'd love is one workflow where I could switch seamlessly between the data analysis and the writing tools. odfWeave did some/most of this, but without the elegant interactivity of Rstudio/knitR. I am loath to give up Zotero, but it make use of all sorts of hidden codes in LibreOffice to do its magic, so it doesn't play nicely with plain text tools like Emacs, etc.
I can't imagine I'm alone in this set of tools, nor in wanting to enhance my workflow. I'd welcome any ideas you had on how knitR/Rstudio and LibreOffice/ZOtero might play together nicely.
Thanks for a great tools!
You might consider pandoc which can convert markdown to LibreOffice ODT, but I do not know how to deal with Zotero citations.
It is entirely possible for knitr to support LibreOffice directly just like odfWeave; I just do not have the time and interest to learn the ODT format... If you know enough about it, you can write your own hook functions for knitr to support ODT.
Originally posted on 2012-05-20 21:35:29
Guest *toprach* @ 2012-05-27 16:23:16 originally posted:
Thanks for knitr ! it works great!
Good to know :) Thanks!
Originally posted on 2012-05-27 16:38:56
Guest *Michal Chmiel* @ 2012-07-11 21:46:33 originally posted:
Would you like to write the article about R language for SDJournal?
Please contact me" michal.chmiel@software.com.pl then I''ll give you more information.
Guest *A535340* @ 2012-07-17 15:55:13 originally posted:
Yihui,
It was nice meeting you at Nashville and I thoroughly enjoyed your talks. I have a question regarding interactive graphs. I run reports for a govt. agency and would like to generate interactive figures for them using googleVis and knitr. However, they are apprehensive about posting these files as html and moreover, they would like a pdf file since it can be saved and does not require an internet connection to view. Is it possible to embed the interactive html figure into the pdf file? Since they would like to print this out and distribute, it would also be great if these figures could be split up automatically into multiple pages when printing. Is this wishful thinking or can this be done using knitR?
Thanks.
Unfortunately, I do not think this is possible. PDF's are for printing purposes and are not supposed to be interactive, just like you cannot interact with a printed report on paper. Life is dull without web technologies. I believe everything will move to the web eventually.
What you can do at best in knitr is to embed animations in PDF (or HTML). You can use fig.show='animate' or 'asis' to decide how to arrange the plots (see http://yihui.name/knitr/options). There is no hope to embed goobleVis in PDF, and I do not believe it makes any sense even to try in that direction.
Originally posted on 2012-07-17 17:43:57
Guest *A535340* @ 2012-07-17 19:48:50 originally posted:
Thank you for your reply. I was however thinking of using your animation package to "animate" or join all those figures together. However the problem still remains that when printing it, only the first figure will show. We are basically trying to show our clients that we can achieve a lot with R, but sadly it is technology at their end that is limiting our final product.
You can use fig.show='asis' for your print version and let whoever enjoys hundreds of boring individual plots read all of them.
Originally posted on 2012-07-17 21:09:21
Guest *Jason* @ 2012-08-07 14:46:23 originally posted:
You may be able to embed layers that can be interactively turned on and off, pan and zoom. A proof of this concept is the GeoPDF format.
Guest *evah* @ 2012-12-09 04:25:10 originally posted:
nice website!
Guest *Isaac Xin Pei* @ 2012-12-12 19:49:58 originally posted:
hi Yihui, bumped into your webiste today and found a 'TON' of great knowledge/information here. Thanks!
BTW, is there a R package, or something to start a didactic conversation regarding a question, and then auto generate a code template of R addressing this type of stats questions? I can use templates, but still, some tool in that capacity will be great/phenomenon.
Best regards,
Isaac
I'm not aware of any packages which have that great amount of intelligence (that is like AI). The sos package might help a little bit for you to search for solutions, though. Another helpful resource is StackOverflow (there are live people who "automatically" answer your questions).
Originally posted on 2012-12-12 23:02:52
Guest *Carl* @ 2013-01-03 17:36:29 originally posted:
Hi Yihui, I saw your post on
http://tex.stackexchange.com/questions/86005/error-with-hyperref-and-the-krantz-class
regarding using hyperref with the Krantz class and your update said that the problem was fixed. Can you please update the discussion with the answer?
I am also having the same problem and have not found the solution.
Thanks, Carl
Yes, the post has been updated.
Originally posted on 2013-01-03 18:04:45
Guest *fstab* @ 2013-03-02 11:54:32 originally posted:
truly impressive work on knitr and R stats. a big thank you!
Guest *Rachel* @ 2013-03-18 15:11:38 originally posted:
How do I get info on the useR! conference?
访客 *CY* @ 2013-04-02 20:19:00 写道:
I will personally sing "千年等一回" to you next time I meet you.
Guest *Lily* @ 2013-04-25 18:07:10 originally posted:
Randomly found this website as searching for some R tips. I studied in ISU back when Snedecor was renovating (the building renewal was completed right after my graduation.. T^T) Anyways, the website is awesome. So is R!
Guest *kldavenport.com* @ 2013-05-30 22:43:40 originally posted:
I use Knitr everyday, thank you so much for your contribution!
访客 *tiger* @ 2013-06-14 13:49:23 写道:
谢意辉,非常佩服你能够写R软件包!向你学习。。。
Guest *Corey Yanofsky* @ 2013-06-18 15:35:15 originally posted:
Another grateful user of knitr here. You are a seriously awesome individual.
Guest *Bernd Gruber* @ 2013-08-30 12:59:18 originally posted:
Hi,
first of all congrats on knitr. Second my apologies if this is not the right place, but as far as I could see on your knitr page comments are closed.
Here is my quesiton. When running knitr for Latex output it converts dots etc. in _ and unfortunately this is causing me headache. As I am try to create with my package a pdf using a function (which is using knitr) in the tempdirectory of R. I have to use the temporary directory due to R policies. This leads to the situation that sometimes when the Rtempfiles has unsuitable characters, they get replaced and then my function breaks down. Is there a way to switch this feature off when knitr is used? Any help is appreciated. I am happy to send you the package (an older version is already on CRAN PopGenReport), but the newer version is much more stable an I am submitting it today (without the vignette because I cannot build it due to the issue mentioned above).
THanks in advance
I'm no longer taking questions on my website, and I have been trying to redirect people to StackOverflow, where you can get more attention and faster answers.
Figure filenames that contain dots won't work for LaTeX, and I only convert the basenames, so I do not see how it can cause trouble. I certainly appreciate more information on that.
Originally posted on 2013-08-31 01:42:36
Guest *Bernd Gruber* @ 2013-09-03 11:50:55 originally posted:
Hi Yihui,
what happens is the following. We have developed a package that uses knitr snippets to create a comprehensive report on data analysis. Basically a function that create a knitr file and this is then passed to knitr. As there is the R policy to use only the tempdir directory (if no other directory is stated) as the default folder where this knitr file ( and the graphics and some other output text files) is created I run into problems under windows as the tempdir folder of windows (and probably other systems) use dots (and spaces) in its path. Therefore the function does not run if the default tempdir function is used and the path is converted by knitr using _ . If there would be a workaround that the path is not converted if tempdir is used that would be fine.
I hope I have expressed myself clearly. If you know another work around this would be highly appreciated. Thanks again for your support
I still do not know how that can happen; knitr does not replace dots/spaces in the directory name with underscores; it only replaces these characters in base filenames, e.g. for a file C:/abc.def ghi/jkl mno.pdf, only "jkl mno.pdf" is converted to jkl_mno.pdf; the dir name is not changed. Therefore it does not matter if the temporary dir contains special chracters or not.
Anyway, you might try to owd = setwd(tmpdir); knit(yourfile); setwd(owd)
You'd better show me a minimal example of what you were doing, or just show me the link to the source that can reproduce the problem. It is difficult to guess and make suggestions.
Originally posted on 2013-09-03 19:39:21
Guest *Bernd Gruber* @ 2013-09-04 00:31:24 originally posted:
Hi Yihui,
thanks for spending time on this. Easiest is probably to reproduce the following. error
if you install the PopGenReport package (version 1.6 just uploaded to CRAN, but only the windows binary is yet available). then type
require(PopGenReport)
data(bilby)
popgenreport(bilby, path.pgr="d:/abc abc")
I get:
Compiling report...
- General summary...
Analysing data ...
Warning in (if (out_format(c("latex", "sweave", "listings"))) sanitize_fn else str_c)(path, :
replaced special characters in figure filename "d:/abc abc/results/PopGenReport-n_alleles_per_locus" -> "d:/abc_abc/results/PopGenReport-n_alleles_per_locus"
Warning in (if (out_format(c("latex", "sweave", "listings"))) sanitize_fn else str_c)(path, :
replaced special characters in figure filename "d:/abc abc/results/PopGenReport-pop_sampsz_vs_alleles" -> "d:/abc_abc/results/PopGenReport-pop_sampsz_vs_alleles"
Creating pdf from: PopGenReport.rnw ...
Finished.
Check PopGenReport.pdf for results.
All files are available in the folder:
d:/abc abc/results
A new folder actually is created abc_abc and the graphs are stored here instead of in abc abc.
I am happy to send you the rnw file if you are so kind to have a look at it. Which email address should I use?
Thanks again,
Bernd
Guest *Bernd Gruber* @ 2013-09-04 14:22:26 originally posted:
Hi,
sorry to have bothered you. I solved the issue with a hint from Kurt Hornik. If I use only relative pathes in the fig.path, then all is fine and I can work in the tempdir. Again thanks again for your time and support. Kind regards,
Bernd
Great! That is also what I meant -- setwd() and use relative paths, but apparently I did not make it clear enough.
Originally posted on 2013-09-04 17:13:30
Guest *qingxp9* @ 2013-09-01 08:54:11 originally posted:
I want to learn how to divide the cn and en site like there,but i still cannot understand after cloning yours from github,could u give me some directions? thank you
cn and en are in the gh-pages branch; yihui.github.com is using the master branch and has a CNAME
Originally posted on 2013-09-03 02:06:16
Guest *qingxp9* @ 2013-09-03 15:46:27 originally posted:
I got it.Now my site is like there too.Thanks for help
Guest *Claudio Shikida* @ 2013-10-24 18:31:59 originally posted:
just a question: why is your kindle book not compatible with many devices? I can't read it at my laptop, mobile..only (luckily) in my tablet. Is there a possibility of fixing it?
Sorry but I do not really know, because I do not have a copy of it. Perhaps you can ask the publisher directly: http://www.crcpress.com/contactus
Originally posted on 2013-10-27 05:54:17
Guest *wafei* @ 2013-10-27 23:34:17 originally posted:
Hi Yihui
As a fifth year Ph.D student in statistics, seems you don't have any research and papers in pure and applied statistics. You spend all your time on coding and R. Is this a reasonable choice or wasting time? Coding and R are just tools for statistics but not statistics.
Guest *Fanglin* @ 2013-10-28 18:58:21 originally posted:
Not all research papers have impact. Yihui's work has.
Guest *wafei* @ 2013-10-30 19:49:59 originally posted:
At least work on some topics which have some impact on applied or theoretical statistics. I don't think anyone who only focuses on fancy R and SAS programming can graduate with a Ph.D in statistics.
Well, I do not care about fanciness. I care about usefulness. Getting a PhD degree is not my goal; "making a dent in the universe" is. There are always people who do or do not understand me. I agree with what you said, anyway.
Originally posted on 2013-11-02 05:24:33
Guest *Chang* @ 2014-02-05 17:24:20 originally posted:
Packages like knitr and ggplot are being used everyday by many statisticians, while many research papers get only a handful downloads in years... I think developing tools for data visualization/reproducible research/... is as important as other PHD topics, if not more.
Guest *PhDStudent* @ 2014-02-19 16:53:11 originally posted:
I can see what you mean, it's more like a cs degree in statistics. But it's his choice, no need to mock him.
I think @wafei's skepticism was reasonable to some degree. He was probably not "mocking" at me. I was just doing something that looked different with other stats PhD's. Anyway, I appreciate your understanding :)
Originally posted on 2014-02-21 21:14:19
Guest *PhD Student* @ 2014-09-16 21:51:10 originally posted:
Research does not only encompass building theoretical and applied knowledge. Science education, outreach, and building tools to aid other scientists are considered vital to research. Funding agencies recognize this.
I agree with you, his work in reproducible research is not pure and applied statistics, but it is every bit as deserving of a Ph.D. in statistics. See Hadley Wickham as an example. We need to encourage and reward more statisticians (and scientists) for building tools.
Guest *ana* @ 2013-11-12 09:22:20 originally posted:
hi Yihui
I am using the package knitr with R2OPENBUGS but when I compile I get this error message "Sorry something went wrong in procedure StdReader.SetPos in module TextModels" can send you more details in private message such as the entire code. any suggestions?
Kind regards
Ana
访客 *Liu Yongli* @ 2014-02-25 03:13:12 写道:
谢师兄,想请教您一些问题,我做多元回归模型,初始数据都不符合正态分布,但是我还是用线性做了,出来R2只有0.2,是不是就是因为不正态分布造成的。现在我就在想怎样增加R2,是对数据转换成正态分布,还是在模型里加二次项。这个问题困扰我好久了,希望谢师兄能指导我一下
访客 *Anna* @ 2014-02-27 01:37:55 写道:
路过,觉得前辈碉堡了>_<
Guest *akdenizduran* @ 2014-03-11 11:58:06 originally posted:
I dont know where the right place is to ask this question. How can I useTurkish characters in R Sweave document?
Guest *Kabir Olorede* @ 2014-03-26 12:35:54 originally posted:
Hello Yihui,
Hope you are doing very well recently. First, I Iike to commend your efforts in developing literate programming especially in Statistics. All your R packages have been very helpful and knowledge contributing, especially the knit r. They are all eye openers. I got to know about R markdown, pan doc and a statistical graphics animation through your works. I have also known Tal Galili earlier through his quality R blogs. Both of you are currently my role models and and distant academic advisors in literate programming. I have now learned writing in Latex using Tex Studio but Statistical animation and graphics is my current interest for my data mining PhD. work. I present what I like you to help me with as soon as possible in what follows:
- My current University requires that I have one year training abroad during my Ph.D. research. Can I come and train under you?
- Buying your knit r book online has been a problem. Please advise.
Guest *stackpop* @ 2014-05-14 03:51:57 originally posted:
hello, i found that your github page's domain structure is what i need, can you help me. http://stackoverflow.com/questions/23644753/muti-repos-github-pages-use-one-top-domain
访客 *Chaofeng* @ 2014-06-17 07:31:18 写道:
做的不错,赞!
Guest *Junyu Lee* @ 2014-06-25 12:08:31 originally posted:
Hi Yihui,
I use Rstudio 0.98944, R 3.1.0 in Win7. When I write my code, I round the numeber to 4 digital use:
para <-round(c(aall4[2],-aall4[1], aall4[4], aall4[3]), 4).
However, the knitred PDF or HTML sometimes showed like
36.52 1.71 2.94 27229.43
sometimes:
28.684 1.638 5.080 48690.369
Even:
6.495e+01 1.785e+00 1.569e+01 3.017e+05
Could you help me with that?
You might be surprised that this question is not really easy to answer. See ?options for the arguments digits and scipen. In your case, format() or formatC() or sprintf() can be better.
Originally posted on 2014-06-25 14:26:14
Guest *Junyu Lee* @ 2014-06-25 21:59:11 originally posted:
Thank you very much. I used sprintf().
Guest *Edwin acuña* @ 2014-06-25 18:03:39 originally posted:
Hi . The reason i am commenting is because i am frustated by my approach about R markdown figure captions. Whenever i create a figure i i set fig.cap="my figure caption" but the figure that is generated does not show the caption. I want something simple like "Figure 1: my figure caption". i saw an example of a report made by a person a he used R markdown to generate the figure caption using fig.cap but so far i have been unable to add it.
Ladies and gentlemen, sorry I have no idea why people started asking me questions here, but this is a personal website, and it is not the right place to ask R questions. Please ask questions here: http://stackoverflow.com/questions/tagged/r (or the rmarkdown website in this case).
Originally posted on 2014-06-25 21:19:17
Guest *anon* @ 2014-07-09 23:55:03 originally posted:
Yihui, Thank you for knitr, mime, and all the rest. You are making a dent in the universe and I wish you can keep making the big contributions.
-Anchorage, Alaska
Thanks!
Originally posted on 2014-07-11 16:10:37
Guest *Caner Gocmen* @ 2014-07-12 14:57:36 originally posted:
Hi Yihui,
I just wanted to echo anon's thoughts. You have made my life and a lot of other people's lives much more easier. Keep up the great work!
Caner
Guest *M M ALI* @ 2014-09-01 21:35:01 originally posted:
I saw your video on Data Science LA and it was really interesting and joy to watch. Thank you for knitr.
My pleasure :)
Originally posted on 2014-09-12 03:35:08
Guest *Guest* @ 2014-09-06 06:34:27 originally posted:
When I use toc: yes option, it may display a correct toc in R's HTML viewer. However, if I output the .Rmd file to .md or .html by using function knit2html(), the toc will disappeared. see https://github.com/nmlascan/getdataPP
knit2html() uses R Markdown v1, and RStudio uses R Markdown v2 by default. To get the same results as in RStudio, call rmarkdown::render() instead of knit2html().
Originally posted on 2014-09-12 03:34:47
访客 *Guest* @ 2014-09-06 07:11:01 写道:
为什么我发表的留言没有了...
Guest *Cliff* @ 2014-09-14 17:29:36 originally posted:
Hello Yihui,
thanks for your huge contributions to the R community. Your tools gave me a huge productivity boost.
May I turn your attention to a stackoverflow question?
I am desperately looking for a solution. Maybe you have an answer?
Guest *Michał Olech* @ 2014-09-28 10:22:24 originally posted:
Dear Sir,
I would like to ask one think. I want to use knitR to produce reports. Let's say, I have 100 lines of data. Each line contains some data for one person. These data feed the report, which I want to prepare in knitR.
Question is: what is - in your opinion - the best way to make the process automatic? I mean: not to click 100 times "Compile PDF" in RStudio :))
For any piece of advice I will be very grateful,
With all the best,
MO
Write a loop, and call the knit() function in knitr. You certainly should not click the button for 100 times...
Originally posted on 2014-10-12 05:29:13
Guest *Brandon* @ 2014-12-08 08:19:01 originally posted:
I really like lyx because I write a lot of equations and they are visually interpretable. However, when I include knitr code in lyx, the document gets cluttered up with Sexpr and <<>>@. I find ` and ``` used in r markup much more visually appealing. Is there a way to combine them both?
There is a way, but it is more hassle than convenience, so I'd rather not tell you...
Originally posted on 2014-12-12 03:36:46
Guest *Juan* @ 2014-12-11 07:42:31 originally posted:
Impressive and inspiring CV!!!
Guest *Juan* @ 2014-12-11 07:46:42 originally posted:
And thanks for knitr!!!
Guest *Alain Mollier* @ 2015-02-26 15:21:22 originally posted:
Hi,
I installed Lyx to use knitr (on W7). I added the R path as you suggested and reconfigured Lyx. I selected Rnw(knitr) module, but I didn't get the menu to add chunck. Moreover I'm not able to generate pdf file from knitr-manual.lyx.
Could you please help me?
Thanks
Guest *kuma* @ 2015-03-16 18:30:21 originally posted:
Hi Yihui Xie,
Thanks a lot for the code to convert html into R table.
I tried mimicing your code, however, I got this error in the third line.
"Error in apply(x[1:2, ], 2, paste, collaps = " "):
dim(x) must have a positive length
Why does it want X to be positive length?
Would appreciate your reply. Thanks
kuma
Guest *twang* @ 2015-03-19 21:59:06 originally posted:
Hi Yihui. I am using knitr::knit2html to convert rmd to html. if I used Rstudio, the pictures show up fine but if i use knitr: knit2html instead, they all show up as . do you know what's going on? could you help me?
I think you need to use rmarkdown::render() instead of knitr::knit2html().
Originally posted on 2015-03-20 00:49:23
Guest *abaldenko* @ 2015-04-03 17:57:54 originally posted:
Hi! I just found the kable() function and I'm trying to reproduce odd/even highlighted tables shown on 'An Introduction to The printr Package'. Do you have any suggestions ?
Guest *Prof Jose Iparraguirre* @ 2015-04-09 16:02:54 originally posted:
Hi Yihui,
I'm starting off with knitr (just got your book).
So far, the examples are working fine within RStudio but not within Texstudio.
I've also read that Lyx may not have all the Latex bits and pieces implemented and that reading a fairly complex .tex document in Lyx is not that straightforward. You see, I've been writing a book for some months now and have written over 100 pages already, and since I've discovered knitr I don't want any longer to create charts in R as png files and ask Latex to read them as figures, etc. Your package is the way forward!
However, TexStudio is my editor of choice and somehow using RStudio just to add a figure here or there in a document is not what I have in mind. I prefer to use Texstudio.
The problem I'm finding has been reported elsewhere but I still can't get around to solving it: it's the rather familiar "Could not start Build & View:PdfLatex" error message within Textstudio when I try to compile a .Rnw file (even the simplest of examples).
I've downloaded everything again (Rstudio, Mitex/Latex, TexStudio, the latest version of R and of the R packages including knitr), and in the TexStudio configuration window I have for PdfLatex this: "C:/Program Files/MiKTeX 2.9/miktex/bin/pdflatex.exe" -synctex=1 -interaction=nonstopmode %.tex
and in the Build window in the User Commands have knitr:knitr and then Rscript -e "library(knitr); knitr(knit2pdf('%.Rnw')"
I've also checked the environmental variables and R is included in the path.
It'd be a pity if I can't keep working with Texstudio, but there's no way back when it comes to use an output generated in R within the document now that I've come across knitr.
Any help, greatly appreciated.
I don't know where you got the (invalid) command knitr(knit2pdf('%.Rnw'); that is not what I wrote in the book or on this page: http://yihui.name/knitr/demo/editors/
Originally posted on 2015-04-11 03:57:38
Guest *Shicheng Guo* @ 2015-08-02 07:14:57 originally posted:
Hi Yihui,
Is there any suggestion on how to prepare figures in then publishing of papers. Here is my confusion. As you know, In order to publish a paper (genomics and bioinformatics), we need spend 4 or 6 month and prepare about 6 figures. For each figure, it will include 4 or 6 sub-figures, such as Figure 1a, 1b, 1c...
Acutally, for each sub-figure, they are created by R or Rstudio independently. And then we will ensemble them into a complete Figure 1. But in this process, some figures need to be re-built since the font maybe too small or some other reasons. Do you have any suggestion or great strategy: how to prepare the figures and publish them with high efficiency and avoid to re-built again and agian?
I have a small post to this question in biostars. but I am not sure I interpret this problem clearly.
https://www.biostars.org/p/152960/
Really hope to get some suggestion from you.
Best regards,
Shicheng
Guest *Yeng Chang* @ 2015-09-11 06:31:25 originally posted:
Hi Yihui,
Proud to say that I found your Dynamic Documents text because of Dr. Maitra at ISU. Thank you so much for the minimal example in there - it helps so much.
Anyway, I have a question for you here. So I tried to copy your minimum example (p. 13, 2nd ed) and it works fine, except for some reason, the data points are not appearing. Here is how I typed the code in the .rnw file:
documentclass{article}
begin{document}
title{A Minimal Example}
author{Yihui Xie}
maketitle
We examine the relationship between speed and stopping distance using a linear regression model:
<<model, fig.width="4," fig.height="3,fig.align='center'">>=
par(mar = c(4, 4, 1, 1), mgp = c(2, 1, 0), cex = 0.8)
plot(cars, pch = 20, col = 'darkgray')
fit <- lm(dist ~ speed, data = cars)
abline(fit, lwd = 2)
@
The slope of a simple linear regression is Sexpr{coef(fit)[2]}.
end{document}
then I asked R to turn it into a .tex file using knitr, and everything works fine, except the plot(cars, pch=20, col = 'darkgray') line. I tried copying and pasting this line into R; the gray points appear. But they don't appear in the .tex file. Am I missing something?
Thank you!
Are you using RStudio or some other editor? For RStudio, you need to change an option (otherwise you will be using Sweave instead of knitr): http://yihui.name/knitr/demo/rstudio/
Originally posted on 2015-09-11 17:03:16
Guest *Yeng Chang* @ 2015-09-11 18:43:04 originally posted:
Nope, I am using the Base R 3.2.2.
How did you compile this document then?
Originally posted on 2015-09-11 19:46:02
Guest *Yeng Chang* @ 2015-09-11 21:27:45 originally posted:
I saved that code as a .rnw file, opened R, did library(knitr) and then knit('my file path') here. Then I opened the .tex file that was outputted via Texmaker and compiled it using PDFLaTeX.
Hmm, it works now for some strange reason. It doesn't show up on the PDF viewer on Texmaker, but it does show up when I open the PDF on Adobe Reader.
Okay, then it sounds like a problem of your TeX editor. You should try RStudio if possible. The knitr support is extremely mature there.
Originally posted on 2015-09-12 02:45:31
Guest *Alasdair Noble* @ 2015-09-22 20:51:04 originally posted:
Hi Yihui,
I have a question on Stack overflow about how knitr goes out through a network to get a map from Google using ggmap. I have code that works fine when I run it normally but if I put it in a knitr program it fails. I don't expect you to know how my work network is configured but if you have any insights about how knitr is likely to access the internet, including setting any permissions etc., it may help our IT guys.
Guest *Xiaoou Wang* @ 2015-11-19 15:11:12 originally posted:
Thank you very much for your knitr Yihui! I've got a weird question, in my thesis I've got a lot of sound that I want my jury to hear when reading the article. Is it possible to have an audioplayer permitting the viewers to play the sound embedded in pdf and implementable by markdown? I know it's not relevant to what you are doing but I really have no clue concerning this question so I post it here with the hope of having some possible solutions.
访客 *JuanMiguelFloresDíaz* @ 2015-11-27 20:46:03 写道:
你幫助人類跨越的空隙寫代碼之間,使得一個關於它的文件,使整個事情進行訪問。非常感謝。
Guest *prateek* @ 2016-08-28 10:12:57 originally posted:
Hi Yihui, just wanted to thank you for the knitr pacakge. Truly amazing! Hope to keep up to date with your latest work. Good luck!
Guest *Amalia Haye* @ 2016-10-27 11:31:00 originally posted:
Yihui, I found you! Thanks!
Guest *Chris* @ 2016-11-14 12:18:34 originally posted:
Hello Yihui,
My name is Chris Flatcher. I represent several
educational websites and currently I'm looking for quality and related websites
for advertising. Your website appears to meet my requirements, thus I'm writing
to inquire if you are interested in text link advertising or sponsored article
publication at your site [probably on some inner pages]. I believe my website
would perfectly suit your website's content and we would greatly supplement
each other's needs.
If interested, please email me back. Hoping for
a positive reply from you soon.
Thanks for your time and attention.
Best regards, Chris Flatcher
Guest *Emmanuel Kemel* @ 2016-12-02 16:51:57 originally posted:
Dear Yihui,
Thank you so much knitr: this is a great tool for research and teaching!
For some reason I cannot use dev='tikz' in Lyx documents. dev='pdf' works in Lyx, and dev='tikz' works from RStudio. Is there any setting of Lyx that I should change?
Thank you so much for your help.
Emmanuel
Guest *yuzhou Chen* @ 2016-12-18 00:20:18 originally posted:
Hi, Yihui. Sorry to bother you. I have a problem when using kniter compile PDF. I only used sf to change the style of "R"( to express R package),but all character after that were changed. Do you know how to figure it out?
Thanks!
Guest *Lars* @ 2017-01-21 22:29:48 originally posted:
Beautiful website!
Guest *Osh* @ 2017-03-26 20:02:33 originally posted:
XSS test
<script> alert('Hello World!'); </script>Guest *Nelson W* @ 2017-06-19 21:41:33 originally posted:
Hi Yihui,
I love the work you've done with R Studio! I've done some academic writing with the Rticles package and I love it! I'm trying to write a journal article to publish in Biometrics, but am having a difficult time figuring out how I would go about adding in the Biometrics document class and such. Do you have any thoughts, or is this something that you'd be open to developing further?
Thanks a bunch!
You may file a feature request to https://github.com/rstudio/rticles/issues and we can take a look when our schedule frees up. Currently I'm afraid everyone is busy, and we can only consider pull requests (i.e. someone does the work and we review it).
Originally posted on 2017-06-20 02:55:42
Guest *Akela* @ 2017-08-14 11:49:14 originally posted:
Help
Hello Yihui Xie
I am computer science student and I am doing the final project route which I must deliver in September.
The project is developed with R, Shiny and I implemented a piece using your
"Radio buttons in a table", but I have a problem that I can not resolve and wanted to know if you could help me.
Thank you
访客 *Yin Xiang* @ 2017-08-25 02:55:37 写道:
Hi,
Come from shiny gallery, "麻麻再也不用担心我的Shiny应用不能显示中文了" its just super cute!!!!!! Made my day !
Thank you !
Glad that you enjoyed it :)
Originally posted on 2017-08-25 04:06:53
Guest *Ye Li* @ 2017-10-10 13:26:00 originally posted:
Hey Yihui, I got a question for you regarding "knit_with_parameters", can you help?
Guest *nicolas* @ 2018-04-03 11:43:49 originally posted:
Hello Yihui, I am insstlled tinytex in my usb drive, but when I chage de directory it faill, what is the correct syntax?
"F:PROGRAMASTinyTexbinwin32tlmgr" path add
Error: unexpected symbol in ""F:PROGRAMASTinyTexbinwin32tlmgr" path"
You cannot run a system command in the R console like that. Instead:
system2("F:PROGRAMASTinyTexbinwin32tlmgr", c("path", "add"))
Originally posted on 2018-04-03 14:05:06
Guest *Nicolas* @ 2018-09-24 15:37:33 originally posted:
Hello yihui I am trying to update tinytex to 2018 version using
tinytex::reinstall_tinytex() but it has error it download the 19 mg
file zip but then it stop the installation, is it a bug?
Many thanks
Try tinytex:::install_prebuilt() instead.
Originally posted on 2018-09-24 16:19:48
Guest *Nicolas Cuenca* @ 2018-09-25 14:10:26 originally posted:
Hello again sorry, with tinytex:::install_prebuilt() r encounter a fatal error and abort session, I am usin r ver 3.3.3 and windows 7 perhaps both are older?
https://yihui.name/en/2017/05/when-in-doubt-upgrade/
Originally posted on 2018-09-25 14:12:45
Guest *Nicolas Cuenca* @ 2018-09-25 14:26:07 originally posted:
Sorry I am not sure, recomend update r or update all packages?
Guest *Nicolas Cuenca* @ 2018-09-25 14:35:44 originally posted:
Or perhaps is possible to downliad texlove packages from a 2017 repository?
Update everything that you are able to update.
Originally posted on 2018-09-25 14:41:17
Guest *Nicolas Cuenca* @ 2018-09-26 08:40:53 originally posted:
Hello yihui sorry, I just discover rstudio cloud an d it appears very good, is possible to download latex packages to rmarkdown pdfs, it generate pdfs but I need install spanish.ldf into babel latex pckage to spanish languaje, I tried with tinytex tlmgr command but show a path problem
Many thanks
访客 *御宅暴君* @ 2018-05-08 01:54:01 写道:
很喜欢你博客,就是不知为啥 Inoreader 总是隔一段时间一口气更新一大堆博文,搞得我没兴趣全看完了。
不是你 RSS 阅读器的问题,而是因为我现在就是隔一段时间推送一大堆:https://yihui.name/cn/2018/02/ninety-posts/
——原帖发布于 2018-05-08 03:52:45
Guest *Masood* @ 2018-05-14 08:47:02 originally posted:
Hi Yihui Xie,
You are inspirational and I think you know that. I really liked your website by the way, and I wanted to ask how did you build it. I would like to make my own one day.
Thanks!
Guest *Kisun Pokharel* @ 2018-07-03 12:06:58 originally posted:
It's mentioned in About section.
访客 *Qianyu Hang* @ 2018-06-03 21:13:34 写道:
哈喽,益辉!最近迷上Markdown,用来写paper,但是page number始终在页脚左边,求问怎么调整位置啊?多谢~ :-D
没有具体的例子很难回答这种问题,因为有无数的可能性。非要我闭眼瞎蒙的话,那只能是在 YAML 元数据中设置 classoption: twoside 了。
——原帖发布于 2018-06-05 04:52:10
Guest *Marty Gleason* @ 2018-06-05 15:18:00 originally posted:
Hi Yihui!
Thank you - for making packages I am starting to use on a daily basis, clear and easy to read documentation, and yolo mode. You are an inspiration to a data-noob like myself.
Guest *Lu* @ 2018-06-29 11:37:01 originally posted:
Hi Yihui,
Just read your blog about "Ghost printing". I'm trying to print out a "flextable"/"regulartable" using knitting a html in Rmarkdown. I tried to put "(mytable)" around my function. It's still not printing. If I use "print(mytable)", the nice format in mytable is lost. Do you have any suggestions on that?
Thanks a lot!
I'm not 100% sure, but you can try knitr::knit_print() instead of print().
Originally posted on 2018-06-29 16:51:40
Guest *Corinna* @ 2018-07-30 22:19:25 originally posted:
Hello,
I love your animation software, however I can't figure out how to save my animated plots. I am using R Studio version 3.5.0
Thanks
Guest *Chang Wen* @ 2018-08-10 18:32:36 originally posted:
hello Yihui,
I have a small question when knitting rmarkdown.
rmarkdown shows error on this code line: a <- read_excel("path",sheet="sheet1",range=a1:c9"), saying "Error in FUN(left,right):non-numeric argument to binary operator calls:...ops.data.table->NextMethod->ops.data.frame->eval". However when running the trunk separately it will not generate error. any idea? thanks in advance
Guest *AMM* @ 2018-08-24 20:09:08 originally posted:
Hi Yihui,
Here is something I have been struggling with in bookdown:
https://stackoverflow.com/questions/51945079/how-to-change-the-figure-caption-format-in-bookdown
I would be grateful if you could help out with that one (or let me know if possible or not).
Kind regards
AMM
Guest *Pablo AB* @ 2018-09-04 15:41:17 originally posted:
Hi Yihui. I need to ask you a question about DT in Shiny.
https://yihui.shinyapps.io/DT-edit/
Can you help me?
Guest *Juan Nicolas Cuenca Zaldivar* @ 2018-09-06 15:32:08 originally posted:
Hello Mr Xie I am trying to use tinytex, I have install the r package but I dont know where donwlload the texlive package; is the standard from texlive or is a custom version from your repository?
Many thanks
Guest *Juan Nicolas Cuenca Zaldivar* @ 2018-09-06 15:53:33 originally posted:
Hello again Mr Xiu; finally I found how to install texlive in r but when I write: install_tinytex(force = FALSE, dir = "auto", repository = "ctan", extra_packages = NULL) it return: trying URL 'http://mirror.ctan.org/systems/texlive/tlnet/install-tl.zip'
length 19926456 bytes (19.0 MB)
downloaded 19.0 MB
downloaded 0 bytes
Error in download.file(url, output, ..., method = method) :
no function to return from, jumping to top level
In addition: Warning message:
In download.file(url, output, ..., method = method) :
URL 'https://github.com/yihui/tinytex/raw/master/tools/pkgs-custom.txt': status was 'SSL connect error'
Please restart your R session and IDE (if you are using one, such as RStudio or Emacs) and check if tinytex:::is_tinytex() is TRUE. I restart r but tinytex:::is_tinytex() is always FALSE
Could you help me?? Many thanks
Please make sure you have the latest version of R: https://yihui.name/en/2017/05/when-in-doubt-upgrade/
If the latest version of R doesn't work, either, please try tinytex:::install_prebuilt().
Originally posted on 2018-09-06 18:19:11
Guest *Henrik* @ 2019-01-29 17:36:41 originally posted:
Hi Yihui,
I've been searching and searching online for an answer to the following question but haven't found any, at least none that works.
Can you read an rtf file into Rstudio/R-Markdown?
I want to create a document using one or more external documents as well as markdown code.
Greatly appreciate any help!
Have you read the R Markdown book? https://bookdown.org/yihui/rmarkdown/rich-text-format-document.html
Originally posted on 2019-01-29 18:21:19
Guest *Henrik* @ 2019-01-30 08:33:18 originally posted:
Yes, I had great hopes when I saw the snippet
knitr::raw_output(readLines('table.rtf'))
but it didn't work for me.
It says Error in file (con, "r") : cannot open the connection Calls: ...asis_output->structure->paste->readLines->file
Guest *Henrik* @ 2019-01-30 17:06:32 originally posted:
I've specified rtf_document as output and setwd to the folder containing the rtf-file but have had no success.
Guest *jcwestland* @ 2019-02-10 19:39:51 originally posted:
Hi Yihui,
I figured you might be the best person to ask about knitr-ing R Markdown that uses both Western and Simplified Chinese characters. There seem to be periodic postings indicating how to do this with ctex.sty and xeCJK when using XeTeX, but I am not able to get any of the solutions to work. There must be a straightforward way to do this. Any suggestions, or a pointer to a web page would be appreciated. I would love to be able to handle this completely through the YAML header.
Guest *Tahor Sui Juris* @ 2019-03-12 23:35:59 originally posted:
Thank you for creating blogdown! Am trying to mimic MKDocs with both the site two level outline theme and a local editor with three levels to allow separate projects like Typora but to include auto publishing. Reading your book blogdown: Creating Websites with R Markdown.
Guest *Tahor Sui Juris* @ 2019-03-13 16:22:08 originally posted:
Hi Yihui,
Some portions of your wonderful book BookDown.org & RMarkDown.RStudio.com/ need modifications. I am reading and reading and reading and adapting the portions that are left out. If interested in what I am experiencing as what is left out, please reply and I can share exactly what should be inserted in your wonderful book.
Guest *Andrew* @ 2019-03-22 09:55:14 originally posted:
Just seen your book on creating websites using blogdown.
Firstly, thanks for putting this on line.
Secondly, I would like to suggest a reflection on the wording used here (https://bookdown.org/yihui/blogdown/a-quick-example.html) footnote 3: with mental health being an increasing issue among students and young people, I wonder if a different phrasing to express your frustration with _index.md might be more appropriate?
All the best
-Andrew
Yes, please feel free to submit a pull request by clicking the Edit button on the toolbar at the top of the page. Thanks!
Originally posted on 2019-03-22 13:37:58
Guest *Sean Yang* @ 2019-04-03 16:56:05 originally posted:
I just watched your webinar about HTML and Leaflet with Java script you provided many months ago. I don't know how to show the sum of clustered groups (using markercluster) on Map. And when I have more than 1 million records, the RStudio crashes on me with Markercluster feature on.
Guest *Kai Yang* @ 2019-04-12 22:07:30 originally posted:
Hey Yihui,
Thanks for rmarkdown, it really helps when I need to write a report. Now I am switching to Jupyter notebook and really missed the kable function from knitr. Any plans to create some equivalent stuff for python?
I'm not a Python programmer, so I definitely won't be able to create the thing you mentioned. I could help with converting Jupyter to R Markdown, though :)
Originally posted on 2019-04-13 02:47:09
Guest *Ethan* @ 2020-01-18 00:52:46 originally posted:
Hi Yihui, can we run multiple SQL statements in a SQL chunk in R markdown? For example,
create table table1 as select * from table2;
select count(*) as cnt from table1;
Right now, it errors out and says "one query is expected".
Thanks!
Guest *Tieming Ji* @ 2020-02-02 16:54:44 originally posted:
Keep up with your coding and cooking skills!
Hi Tieming, it's great (and a surprise) to see you here! I'll definitely keep up with my cooking skills. For coding, I'm not sure how long I could still keep up with it :)
Originally posted on 2020-02-03 15:43:35
Guest *Ethan* @ 2020-02-04 23:10:07 originally posted:
When I run "create table" in a sql chunk, it returns error. It seems that it errors out if nothing is returned. Can we change it.
Error in .verify.JDBC.result(r, "Unable to retrieve JDBC result set for ", :
Unable to retrieve JDBC result set for create table t1 as
select user_id from t2 limit 2; ([JDBC Driver]com.amazon.dsi.dataengine.impl.DSISimpleRowCountResult cannot be cast to com.amazon.dsi.dataengine.interfaces.IResultSet)
Failed to execute SQL chunk
Guest *otakutyrant* @ 2020-05-20 05:59:06 originally posted:
Today, I have a profound question: What do you gain in English writing?
I just write a lot.
Originally posted on 2020-05-20 19:36:40
Guest *Dan Li* @ 2020-08-12 20:10:37 originally posted:
Hi Yihui,
When I Knit the chunk, the results can show in rmarkdown but can't show in output files. Can you tell me why?
system2("wsl", "cd ~/bioinfor/; ls")
Thanks a lot!
Because system2() writes the output to stdout, which can't be captured by R unless you call system2(stdout = TRUE). That said, why not use the bash or sh engine?
```{sh}
wsl
cd ~/bioinfor/
ls
```
BTW, system2("wsl", "cd ~/bioinfor/; ls") is probably not a valid call, unless you meant to run the command:
wsl "cd ~/bioinfor/; ls"
I don't know what wsl is, so I'm not sure.
Originally posted on 2020-08-12 20:39:52
Guest *Dan Li* @ 2020-08-12 20:49:59 originally posted:
Thanks for so quick response. Maybe you use mac, wsl is windows subsystem linux. I have to use linux command line to analysis data. I try to commbine the R code with bash code using rmarkdown. Thanks for making the great tool.
Guest *Edgar* @ 2020-08-16 01:58:35 originally posted:
Hi Yihui. I'm trying to add my blog to Rbloggers but I get that my feed results in the "XML document is invalid" error. As of Hugo v0.58.2, the solution accepted on Stack Overflow is no longer working: https://stackoverflow.com/questions/48997278/how-do-i-get-my-blogdown-blog-on-r-bloggers
How can we fix this?
Guest *Dan Li* @ 2020-09-04 18:09:03 originally posted:
Hi Yihui,
When I use Lua filters to change the text color in blogdown, the change works well after rmarkdown::render(), but the changes can't show up after blogdown::hugo_build() and blogdown:::serve_site(). Can you please tell me why?
output:
html_document:
pandoc_args: --lua-filter=color-text.lua
Thanks a lot.
Sorry, but it's impossible for me to answer all your questions here. Please read and follow the guide https://yihui.org/issue/ if you have more questions.
Originally posted on 2020-09-05 02:03:01
Guest *Dan Li* @ 2020-09-05 19:14:16 originally posted:
Sorry, Good suggestion. Thanks very much.
Guest *이해원* @ 2021-01-27 00:10:42 originally posted:
Yihui,
thank you for rmarkdown and many many authoring tools.
To make medical research papers, I'm using ztable package which has some good features like highlighting table and table statistics, however, it is not supported by rmarkdown.
Making Latex code into txt file and inserting in the rmd is one of the solutions, but I wish I can use ztable function inside code chunk like kable function.
Please consider universal method knitting automatically generated
Latex codes inside the code chunk.
I found that many other users have same issues, but I can't find answers.
Best solution was inserting with input {generated latex txt}
With best,
Haewon Lee
I'm not familiar with ztable, but you can insert the R code chunk into a Pandoc raw tex block: https://bookdown.org/yihui/rmarkdown-cookbook/raw-latex.html
Originally posted on 2021-01-27 02:00:56
Guest *이해원* @ 2021-01-27 03:48:06 originally posted:
thank you for quick response
I had read that but that's typing instead of generating
Is there any method that
I make paste("hline"
"Patient.No. & 7.0 ± 3.3 & 1.0 ± NA & & & 109.5 ± 53.8 & 31.5 ± 1.9 & 0.000 " ," - no & 11 (100.0%) & 0 ( 0.0%) & & & 172 (94.0%) & 1 (16.7%) & " , "hline" )
and knitting can be done by just printing text containing latex code?
Guest *이해원* @ 2021-01-27 04:05:11 originally posted:
Aaaaahh..
I found the solution
I didn't know the result="asis" option
print(ztable(mytable(cancer~.,data=df)), type="latex")
problem was my ignorance
Guest *Peter Allen Robertson* @ 2021-03-09 06:27:30 originally posted:
I've been trying to read your book "Bookdown" for some time. Quite frankly, it is a hard read. I'm trying to follow the mechanics of bookdown, and it is a tad confusing! Just to do a simple book is proving quite a chore; I like to see some sort of order in the files needed to create a book, like yaml files before or after rmd files and are there any other strange files I need to add (not images or text files).
Sign in to join the discussion
Sign in with GitHub