GithubHelp home page GithubHelp logo

Comments (2)

retiuk avatar retiuk commented on May 2, 2024 1

It worked, makes sense that channel_constr_low should be a vector.

Thanks Leo!

from robyn.

Leonelsentana avatar Leonelsentana commented on May 2, 2024

Hey Fede,

Hope you are well and thanks for trying our code. Let me show you a best practice example so that you copy it on your end:

model_output_collect$allSolutions
optim_result <- f.budgetAllocator(modID = "2_16_3" # input one of the model IDs in model_output_collect$allSolutions to get optimisation result
                                  ,scenario = "max_historical_response" # c(max_historical_response, max_response_expected_spend)
                                  #,expected_spend = 100000 # specify future spend volume. only applies when scenario = "max_response_expected_spend"
                                  #,expected_spend_days = 90 # specify period for the future spend volumne in days. only applies when scenario = "max_response_expected_spend"
                                  ,channel_constr_low = c(0.25, 0.25, 0.25, 0.25, 0.25, 0.25) # must be between 0.01-1 and has same length and order as set_mediaVarName
                                  ,channel_constr_up = c(3, 3, 3, 3, 3, 3) # not recommended to 'exaggerate' upper bounds. 1.5 means channel budget can increase to 150% of current level
)

Please note to just comment the lines with '#' for expected_spend and expected_spend_days as well as, putting one channel_constr_low and one channel_constr_up per each channel involved. In the example above we have 6 channels to assess.
Names is used basically to see if the number of channels listed in the optimization actually match the ones that are used in the budget allocator.

Let me know if that works,
Hope it helps!
Thanks,
Leo

from robyn.

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.