Git Product home page Git Product logo

Comments (5)

delosh653 avatar delosh653 commented on August 28, 2024

Solution, unfortunately, found. On Macs/Unix-based systems, you can't use the double backslash to refer to file references ("\"). You have to use forward slashes ("/"). So the solution for the above piece of code would be:

 r2d3(data = data_to_json(dat_sankey), script = "js_scripts/all_tabs.js", 
         d3_version = 5, 
         dependencies = c("js_scripts/sankey/d3-sankey.js",
                          "js_scripts/sankey/d3-sankey.min.js"),
         options = list("all_sig"=all_sig,
                        "sig_color"=unname(sig_color),
                        "no_sig_color"=no_sig_color,
                        "font_size" = font_size,
                        "which_camp" = "ont_map",
                        textcol_bg = textcol_bg,
                        togg_border = togg_border
         ))

Closing this issue (though hopefully some woefully unknowing windows user like me finds this helpful!).

from r2d3.

jjallaire avatar jjallaire commented on August 28, 2024

Use forward slashes are valid on both Windows & Posix systems so is generally how all path references are composed in R.

from r2d3.

delosh653 avatar delosh653 commented on August 28, 2024

If you're on windows, the above double backslashing reference would work (this is easier to add one backslash when copying references from windows). So this isn't well known for people like me, who work almost exclusively in a windows environment. But good to know for me for the future!

from r2d3.

jjallaire avatar jjallaire commented on August 28, 2024

from r2d3.

delosh653 avatar delosh653 commented on August 28, 2024

Wow, great to know about the "file.path" command! Thank you for the tip!

from r2d3.

Related Issues (20)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.