Documentation ¶
Index ¶
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func WeekDayString ¶
WeekDayString returns the weekDay English string
Types ¶
type Report ¶
type Report struct {
Analysis []ReportValue `json:"analysis"`
}
func ReportHourly ¶
func ReportHourly(consumptions *parser.Consumptions) Report
ReportHourly makes calculations (Mean) by hour based on the electricity consumption
func ReportWeekDays ¶
func ReportWeekDays(consumptions *parser.Consumptions) Report
ReportWeekDays Analyzes the Consumption done based on weeekdays intervals and returns the consumption avg for each weekDay
type ReportValue ¶
type ReportWeekDayHourly ¶
type ReportWeekDayHourly struct { WeekDay *int `json:"weekDay,omitempty"` WeekString *string `json:"weekString,omitempty` Analysis Report `json:"report,omitempty"` }
func ReportWeekDaysHourly ¶
func ReportWeekDaysHourly(consumptions *parser.Consumptions) []ReportWeekDayHourly
Analyzes the Consumption done based on weeekdays intervals and returns the consumption avg for each weekDay
type ResponseReport ¶
type ResponseReport struct { WeekDaysReport Report `json:"weekDaysReport"` HourlyReport Report `json:"hourlyReport"` WeekDayHoursReport []ReportWeekDayHourly `json:"weekdayHoursReport"` }
Click to show internal directories.
Click to hide internal directories.