Giter VIP home page Giter VIP logo

Comments (4)

jrosen48 avatar jrosen48 commented on August 14, 2024

Hm, I'm a bit confused by this, also from the manual, which seems to suggest you cannot combine the above two functions into one function:

Targets with the "file" format are called dynamic files, and these targets are unusual because their return values do not get saved in the _targets/objects/ folder. Rather, they expect you to return a character vector files and directories, which gets stored in the _targets/meta spreadsheet, and then targets watches the data at those paths for changes.

from comparing-sentiment.

jrosen48 avatar jrosen48 commented on August 14, 2024

But does section 4.3 of the manual suggest that we could create an imported function that both loads (or saves) the file, but still returns a file path.

from comparing-sentiment.

conradborchers avatar conradborchers commented on August 14, 2024

Good point! You can save targets objects as external files and return their path, but then you need to re-read in that path in order to reference these objects inside the pipeline at later target steps. In short: If you want to keep referencing data frames without an additional read-in step, you need to make these two steps. At some points it makes sense to save targets objects externally but I think its not the best idea to do it at all steps. Lastly, I think that tar_target(ss_scale_file, read.table(here("data-sentiment", "sentistrength_scale.txt"), sep="\t", header = T, quote=""), format="file"), would not work since a data object would be returned by the type expects a path/string. Will touch on that in the meeting later today!

from comparing-sentiment.

jrosen48 avatar jrosen48 commented on August 14, 2024

from comparing-sentiment.

Related Issues (11)

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.