Question-and-Answer Resource for the Building Energy Modeling Community
Get started with the Help page
Ask Your Question
2

Problems getting ScheduleRuleset value

asked 4 years ago

updated 4 years ago

I am writing an Openstudio measure that needs to access the values defined in a schedule defined by "ScheduleRuleset" with different rules. I have written something like this:

sch = model.getScheduleRulsetByName("Schedule name").get
start_date = OpenStudio::Date.new(OpenStudio::MonthOfYear.new("Jan"), 1)
end_date = OpenStudio::Date.new(OpenStudio::MonthOfYear.new("Dec"), 31)

I have the following problems:

  • sch.getDaySchedules(start_date, end_date) always returns the default day (although there are other rules defined for these days)
  • sch.getActiveRuleIndices(start_date, end_date) always returns an array filled with -1 (no valid rule for this day).

What am I doing wrong? Is there another way to get the schedule values?

Preview: (hide)

1 Answer

Sort by » oldest newest most voted
2

answered 4 years ago

This sounds similar to the question asked here. Does the answer there address your issue?

Preview: (hide)
link

Comments

Sorry for my previous poor research. It is the same problem, but the solution given, didn't work for me. I continue the discussion in that thread. Thanks.

mapascual's avatar mapascual  ( 4 years ago )

Your Answer

Please start posting anonymously - your entry will be published after you log in or create a new account.

Add Answer

Training Workshops

Careers

Question Tools

1 follower

Stats

Asked: 4 years ago

Seen: 130 times

Last updated: May 13 '20