class: center, middle # papr: Tinder for pre-prints Lucy D'Agostino McGowan Nick Strayer Jeff Leek  --- class: center, middle # what is tinder?  .footnote[useR!2017 \#RChickenLadies] --- layout: true .footnote[useR!2017] --- class: center, middle # what is papr?  --- # history <i class = "fa fa-twitter"></i> <blockquote class="twitter-tweet" data-lang="en"><p lang="en" dir="ltr">I built a "tinder for academic preprints" web app: <a href="https://t.co/fZYlgkn4WL">https://t.co/fZYlgkn4WL</a> for <a href="https://twitter.com/biorxivpreprint">@biorxivpreprint</a> preprints.</p>— Jeff Leek (@jtleek) <a href="https://twitter.com/jtleek/status/782949505754861568">October 3, 2016</a></blockquote> <blockquote class="twitter-tweet" data-lang="en"><p lang="en" dir="ltr">Hilarious 😂 If only it was compatible with swiping..the tactile enjoyment of making snap judgements by swiping left/right is unrivaled <a href="https://twitter.com/hashtag/papr?src=hash">#papr</a> <a href="https://t.co/isg5hmsh7n">https://t.co/isg5hmsh7n</a></p>— Lucy 🌻 (@LucyStats) <a href="https://twitter.com/LucyStats/status/782953224420495365">October 3, 2016</a></blockquote> <blockquote class="twitter-tweet" data-lang="en"><p lang="en" dir="ltr">.<a href="https://twitter.com/LucyStats">@LucyStats</a> I'm with you, maybe <a href="https://twitter.com/jcheng">@jcheng</a> can add swiping functionality to Shiny?</p>— Jeff Leek (@jtleek) <a href="https://twitter.com/jtleek/status/782953550091542528">October 3, 2016</a></blockquote> --- # history <i class = "fa fa-twitter"></i> <blockquote class="twitter-tweet" data-lang="en"><p lang="en" dir="ltr">Agreed. <a href="https://twitter.com/jcheng">@jcheng</a> I'd appreciate it if you would make this a top priority 💁🏻</p>— Lucy 🌻 (@LucyStats) <a href="https://twitter.com/LucyStats/status/782958062378377216">October 3, 2016</a></blockquote> <blockquote class="twitter-tweet" data-lang="en"><p lang="en" dir="ltr">I'm looping you in <a href="https://twitter.com/NicholasStrayer">@NicholasStrayer</a> can you do some javascript magic to make this happen ✨💻 </p>— Lucy 🌻 (@LucyStats) <a href="https://twitter.com/LucyStats/status/782967208649580545">October 3, 2016</a> </blockquote> <blockquote class="twitter-tweet" data-lang="en"><p lang="en" dir="ltr">swipR: the tidyverse judge-a-book-by-its-cover <a href="https://twitter.com/hashtag/rstats?src=hash">#rstats</a> package.</p>— Nick Strayer (@NicholasStrayer) <a href="https://twitter.com/NicholasStrayer/status/782978330316382208">October 3, 2016</a> </blockquote> --- # history <i class = "fa fa-twitter"></i> <blockquote class="twitter-tweet" data-lang="en"><p lang="en" dir="ltr">yep done we're making it. Cube meeting at 3.</p>— Lucy 🌻 (@LucyStats) <a href="https://twitter.com/LucyStats/status/782978971596185602">October 3, 2016</a> </blockquote> <blockquote class="twitter-tweet" data-lang="en"><p lang="en" dir="ltr">Cube meeting mission accomplished <a href="https://twitter.com/hashtag/highfivingamillionangels?src=hash">#highfivingamillionangels</a> <a href="https://t.co/qibMzCD8kd">pic.twitter.com/qibMzCD8kd</a></p>— Lucy 🌻 (@LucyStats) <a href="https://twitter.com/LucyStats/status/783066294115569665">October 3, 2016</a></blockquote> --- # stats <span class="fa-stack fa-lg"> <i class="fa fa-circle fa-stack-2x"></i> <i class="fa fa-users fa-stack-1x fa-inverse"></i> </span> 13,000+ sessions <br><br> <span class="fa-stack fa-lg"> <i class="fa fa-circle fa-stack-2x"></i> <i class="fa fa-sign-in fa-stack-1x fa-inverse"></i> </span> 1,800+ unique logins <br><br> <span class="fa-stack fa-lg"> <i class="fa fa-circle fa-stack-2x"></i> <i class="fa fa-twitter fa-stack-1x fa-inverse"></i> </span> 450+ provided Twitter credentials <br><br> ---  ---  --- # unique aspects <span class="fa-stack fa-lg"> <i class="fa fa-circle fa-stack-2x"></i> <i class="fa fa-sign-in fa-stack-1x fa-inverse"></i> </span> saving data for multiple logins <br><br> <span class="fa-stack fa-lg"> <i class="fa fa-circle fa-stack-2x"></i> <i class="fa fa-laptop fa-stack-1x fa-inverse"></i> </span> running the app locally with a specific port <br><br> <span class="fa-stack fa-lg"> <i class="fa fa-circle fa-stack-2x"></i> <i class="fa fa-floppy-o fa-stack-1x fa-inverse"></i> </span> saving API credentials <br><br> --- # unique aspects <span class="fa-stack fa-lg"> <i class="fa fa-circle fa-stack-2x"></i> <i class="fa fa-hand-o-up fa-stack-1x fa-inverse"></i> </span> incorporating tactile input <br><br> <span class="fa-stack fa-lg"> <i class="fa fa-circle fa-stack-2x"></i> <i class="fa fa-thumbs-up fa-stack-1x fa-inverse"></i> </span> creating a recommender engine <br><br> --- class: center, middle [https://jhubiostatistics.shinyapps.io/papr](https://jhubiostatistics.shinyapps.io/papr/) ---  ---  --- [](https://github.com/MarkEdmondson1234/googleAuthR) --- # Google credentials  --- # Google credentials  --- # tell shiny ```r shiny::runApp(port=1221) ``` ---  ---  ---  --- # pop-up ```r library("shiny") library("shinysense") terms_content_div <- div( p("Here are some terms for you to ignore") ) ui <- fixedPage( shinypopupUI("terms", buttonText = "I understand, let's get swiping!", popupDiv = terms_content_div, "test" ) ) server <- function(input, output, session) { callModule(shinypopup, "terms", accepted = FALSE) }) ``` --- # pop-up ```r library("shiny") library("shinysense") *terms_content_div <- div( * p("Here are some terms for you to ignore") * ) ui <- fixedPage( shinypopupUI("terms", buttonText = "I understand, let's get swiping!", popupDiv = terms_content_div, "test" ) ) server <- function(input, output, session) { callModule(shinypopup, "terms", accepted = FALSE) }) ``` --- # pop-up ```r library("shiny") library("shinysense") terms_content_div <- div( p("Here are some terms for you to ignore") ) ui <- fixedPage( * shinypopupUI("terms", * buttonText = "I understand, let's get swiping!", * popupDiv = terms_content_div, * "test" ) ) server <- function(input, output, session) { callModule(shinypopup, "terms", accepted = FALSE) }) ``` --- # pop-up ```r library("shiny") library("shinysense") terms_content_div <- div( p("Here are some terms for you to ignore") ) ui <- fixedPage( shinypopupUI("terms", buttonText = "I understand, let's get swiping!", popupDiv = terms_content_div, "test" ) ) server <- function(input, output, session) { * callModule(shinypopup, "terms", accepted = FALSE) }) ``` ---  ---  ---  ---  --- # save credentials ```r library("rdrop2") token <- drop_auth() saveRDS(token, "papr-drop.rds") ``` --- # save credentials ```r library("rdrop2") token <- drop_auth() *saveRDS(token, "papr-drop.rds") ``` *be sure to stick this in your .gitignore* 🙊 ---  --- # swipr ```r library("shiny") library("shinysense") ui <- fixedPage( shinyswiprUI("my_swiper", h4("Swipe Me!"), hr(), p("This is some swipe-happy content") ) ) server <- function(input, output, session) { card_swipe <- callModule(shinyswipr, "my_swiper") observeEvent(card_swipe(), { print(card_swipe()) #show last swipe result. }) } ``` --- # swipr ```r library("shiny") library("shinysense") ui <- fixedPage( * shinyswiprUI("my_swiper", h4("Swipe Me!"), hr(), p("This is some swipe-happy content") ) ) server <- function(input, output, session) { card_swipe <- callModule(shinyswipr, "my_swiper") observeEvent(card_swipe(), { print(card_swipe()) #show last swipe result. }) } ``` --- # swipr ```r library("shiny") library("shinysense") ui <- fixedPage( shinyswiprUI("my_swiper", h4("Swipe Me!"), hr(), p("This is some swipe-happy content") ) ) server <- function(input, output, session) { * card_swipe <- callModule(shinyswipr, "my_swiper") observeEvent(card_swipe(), { print(card_swipe()) #show last swipe result. }) } ``` --- # swipr ```r library("shiny") library("shinysense") ui <- fixedPage( shinyswiprUI("my_swiper", h4("Swipe Me!"), hr(), p("This is some swipe-happy content") ) ) server <- function(input, output, session) { card_swipe <- callModule(shinyswipr, "my_swiper") * observeEvent(card_swipe(), { print(card_swipe()) #show last swipe result. }) } ``` ---  ---  ---  --- # PCA plotly
---  --- # thank you <span class="fa-stack fa-lg"> <i class="fa fa-circle fa-stack-2x"></i> <i class="fa fa-sign-in fa-stack-1x fa-inverse"></i> </span> [https://jhubiostatistics.shinyapps.io/papr](https://jhubiostatistics.shinyapps.io/papr/) <i class="fa fa-cog fa-spin fa-2x fa-fw"></i> [https://github.com/jhudsl/papr](https://github.com/jhudsl/papr) <span class="fa-stack fa-lg"> <i class="fa fa-circle fa-stack-2x"></i> <i class="fa fa-toggle-right fa-stack-1x fa-inverse"></i> </span> [http://rpubs.com/lucymcgowan/papr](http://rpubs.com/lucymcgowan/papr) <span class="fa-stack fa-lg"> <i class="fa fa-circle fa-stack-2x"></i> <i class="fa fa-twitter fa-stack-1x fa-inverse"></i> </span> [@LucyStats](https://twitter.com/LucyStats)