๐ Add a function that will replace each letter with an emoji
LucyMcGowan opened this issue ยท comments
An ode to my favorite princess.
Carrie Fisher often wrote in emojis by replacing each letter with an emoji that resembled it. For example,
emo::ji_fisher("without you I would just be a weird chick in a hat")
#> ใฐโนโ๏ธโ๏ธ๐
พ๏ธโโ๏ธ โ๐ป๏ธ๐
พ๏ธโ โน ใฐ๐
พ๏ธโ๐d ๐ถโ๐ฒโ๏ธ ๐
ฑ๏ธ๐ง๐
ฐ๏ธ ใฐโน๐งยฎd ยฉโ๏ธโนยฉ๐ โน๏ธโ๏ธ ๐
ฐ๏ธ โ๏ธ๐
ฐ๏ธโ๏ธ
ref: tweet
emo::ji_fisher("Im supposed to tell you to buy my book, but Im not really like that!")
#> โนโ๏ธ ๐ฒโ๐
ฟ๏ธ๐
ฟ๏ธ๐
พ๏ธ๐ฒ๐งd โ๏ธ๐
พ๏ธ โ๏ธ๐ง๐๐ โ๐ป๏ธ๐
พ๏ธโ โ๏ธ๐
พ๏ธ ๐
ฑ๏ธโโ๐ป๏ธ โ๏ธโ๐ป๏ธ ๐
ฑ๏ธ๐
พ๏ธ๐
พ๏ธ๐, ๐
ฑ๏ธโโ๏ธ โนโ๏ธ โ๏ธ๐
พ๏ธโ๏ธ ยฎ๐ง๐
ฐ๏ธ๐๐โ๐ป๏ธ ๐โน๐๐ง โ๏ธโ๏ธ๐
ฐ๏ธโ๏ธโ
ref: tweet
emo::ji_fisher("I love the new rstudio")
#> โน๏ธ ๐โค๏ธโ๏ธ๐ง ๐ดโ๏ธ๐ง ๐ ยฎ๏ธโก๏ธ๐ดโโฉ๏ธโน๏ธโญ๏ธ
A bit similar to #5, but different in that rather than replace full words, it would just replace letters.
That'd be cool.
This would allow me to participate to slack://ropensci#allemoji
Are all those emojis ? or do we need to also poke into other unicode planes, e.g.
> filter( uni::code, str_detect(description, "registered") )
# A tibble: 1 x 7
id rune description block countries languages type
<int> <chr> <chr> <chr> <chr> <chr> <chr>
1 174 U+00AE Registered Sign : registered trade mark sign latin-1-supplement <NA> <NA> <NA>
Some of Carrie's weren't emojis, but I think as a first pass we can just use emojis? I have at least a 1:1 alphabet to emoji mapping I generally use I can write up.
cool. It does not necessarily need to be 1:1 some letters (o) might have many proxy emojis .. ji_fisher
could randomly select one
Here is a start of the mapping ๐ธ (I ended up sticking it in a ๐ฆ so it's easier to play with, but it is only a small dataset + function)
Would you prepare a PR for emo ?
Cple of things though:
- please use purrr instead of sapply
- return a string w class "emoji" instead of directly cat it, print.emoji will cat it. It makes the function
Yep! How would you like the data saved? Right now I create a tibble, turn it into a list, and then export that.
That sounds fine