2

Problems getting ScheduleRuleset value

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?

mapascual's avatar
653
mapascual
asked 2020-05-13 11:14:42 -0500
__AmirRoth__'s avatar
4.4k
__AmirRoth__
updated 2020-05-14 08:24:40 -0500
edit flag offensive 0 remove flag close merge delete

Comments

add a comment see more comments

1 Answer

2

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

shorowit's avatar
11.8k
shorowit
answered 2020-05-13 17:01:15 -0500
edit flag offensive 0 remove flag delete 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 (2020-05-14 07:07:49 -0500) edit
add a comment see more comments