TAlked by SiNo Xmen's Pets
tanx(which = NULL, sinxs.data = NULL, what = "Hello world!", by = "random", type = "message", what_color = "steelblue3", by_color = NULL, length = 18, ...)
which | An integer specifying the row number of sinxs.data. Alternatively which can be a character and grep is used to try to find a suitable row. |
---|---|
what | (character) What do you want to say? See details. |
by | (character) Type of thing, one of cow, chicken, poop, cat, facecat,
bigcat, longcat, shortcat, behindcat, longtailcat, anxiouscat, grumpycat,
smallcat, ant, pumpkin, ghost, spider, rabbit, pig, snowman, frog, hypnotoad,
signbunny, stretchycat, fish, trilobite, shark, buffalo, clippy, mushroom,
monkey, egret, or rms for Richard Stallman.
Alternatively, use "random" to have your message spoken by a random
character.
We use |
type | (character) One of message (default), warning, or string
(returns string). If multiple colors are supplied to |
what_color | (character or crayon function) One or more
|
by_color | (character or crayon function) One or more
|
length | (integer) Length of longcat. Ignored if other animals used. |
... | Further args passed on to |
You can put in any phrase you like, OR you can type in one of a few special phrases that do particular things. They are:
catfact A random cat fact from https://catfact.ninja
fortune A random quote from an R coder, from fortunes library
time Print the current time
rms Prints a random 'fact' about Richard Stallman from the
rmsfact
package. Best paired with by = "rms"
.
Note that if you choose by='hypnotoad'
the quote is forced to be,
as you could imagine, 'All Glory to the HYPNO TOAD!'. For reference see
http://knowyourmeme.com/memes/hypnotoad
Signbunny: It's not for sure known who invented signbunny, but this article http://www.vox.com/2014/9/18/6331753/sign-bunny-meme-explained thinks they found the first use in this tweet: https://twitter.com/wei_bluebear/status/329101645780770817
Trilobite: from http://www.retrojunkie.com/asciiart/animals/dinos.htm (site down though)
Note to Windows users: there are some animals (shortcat, longcat, fish, signbunny, stretchycat, anxiouscat, longtailcat, grumpycat, mushroom) that are not available because they use non-ASCII characters that don't display properly in R on Windows.
tanx()#> #> #>#>for (i in 1:4) tanx(i)#> #> 这个问题我很感兴趣。能否提供一个可以重现问题的数据和代码示例,让我直接拷贝粘贴就能运行?最好附带 `session_info()` 信息。 #> #> #> #> #> #> #> #> #> #> #> #> #> #> #> #> #> #> #> #> #>#>#> #> #> Sweave 好像就是一边编译 LaTeX 的时候就可以一边执行程序源代码并即时输出结果,我也没正式用过…… #> #> #> #> #> #> #> #> #> #> #> #> #> #>#>#> #> #> 节约别人的时间,就是节约自己的时间。 #> #> #> #> #> #> #> #> #> #> #> #> #> #> #> #> #> #> #> #> #> #> #> #> #> #> #> #>#>#> #> #> 奇怪了你的代码在我的机器上完全没有问题啊 #> #> #> #> #> #> #> #> #> #> #> #> #> #> #> #> #> #> #> #> #>#>path_f <- system.file("fortunes/fortunes.csv", package = "fortunes") path_s <- system.file("sinxs/sinxs.csv", package = "sinx") ftns <- sinx::read.sinxs(c(path_f, path_s), sep = c(";", ",")) sinx::tanx(sinxs.data = ftns)#> #> Ted Harding: But you can also do these with 'any' and 'all', e.g. any(v==TRUE).<x>Thomas Lumley: or any( (v==TRUE)==TRUE), or any( ((v==TRUE)==TRUE)==TRUE)... Or, perhaps, any(v). Lewis Carroll wrote a nice piece on this theme. #> #> #> #> #> #> #> #> #> #> #> #> #> #> #> #> #> #> #> #> #> #> #> #> #>#>#> #> 一梦如是。 #> #> #> #> #> #> #> #>#>libs <- read.sinxs(lib = c("tangshi", "songshi", "chinese", "yangsheng", "english", "jinyong")) tanx(42, sinxs.data = libs)#> #> #> 风吹柳花满店香,吴姬压酒唤客尝。 #> #> #> #> #> #> #> #> #> #> #> #> #> #>#>