Code Monkey home page Code Monkey logo

Comments (10)

neo0351 avatar neo0351 commented on August 25, 2024 1

Oh, sorry, missed that you linked another data set

from spectratrait.

serbinsh avatar serbinsh commented on August 25, 2024

Pretty sure this is the area causing problems

create_data_split <- function(approach=NULL, split_seed=123456789, prop=0.8,
                              group_variables=NULL) {
  set.seed(split_seed)
  if(!is.null(approach)) {
    if (approach=="base") {
      plsr_data$CalVal <- NA
      split_var <- group_variables
      plsr_data$ID <- apply(plsr_data[, split_var], MARGIN = 1, FUN = function(x) paste(x, collapse = " "))

from spectratrait.

neo0351 avatar neo0351 commented on August 25, 2024

can you email me the data set you are using? I agree, this needs to work on any data set.

from spectratrait.

serbinsh avatar serbinsh commented on August 25, 2024

I provided the EcoSIS link to the dataset? Do you actually need me to email it to you?

from spectratrait.

neo0351 avatar neo0351 commented on August 25, 2024

@serbinsh Ok, I see the problem. It's the grep looking for NA's. Which will cause issues. I've solved this once upon a time and don't remember the fix right now. The real question is, how do we want to handle say species that has NA's in it? Drop them? Leave them?

from spectratrait.

neo0351 avatar neo0351 commented on August 25, 2024

@serbinsh What do we want to do with NA's in the grouping variables?

from spectratrait.

serbinsh avatar serbinsh commented on August 25, 2024

We dont want to drop NA's. I think we may just have to shunt them as another "factor" that is pool all NA's together. What do you think? The risk is dropping NAs could mean we drop a lot of good data for training

from spectratrait.

neo0351 avatar neo0351 commented on August 25, 2024

Good point. I'll keep them in. We should check Julien's method and see what it does.

from spectratrait.

neo0351 avatar neo0351 commented on August 25, 2024

I'll get you the fix after lunch. I think I need to update all the things before submitting the fix.

from spectratrait.

serbinsh avatar serbinsh commented on August 25, 2024

Fixed by @neo0351

from spectratrait.

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.