MonthlyWeatherStatisticsQuery
A structure that encapsulates a generic monthly weather statistics dataset request.
Declaration
struct MonthlyWeatherStatisticsQuery<T> where T : Decodable, T : Encodable, T : Equatable, T : SendableOverview
Use the properties of this structure to create a monthly weather statistics query. You can combine multiple queries into a single WeatherService request.
Here’s how to get monthly weather statistics for New York City:
let (monthlyPrecipitationStatistics, monthlyTemperatureStatistics) = try await service.monthlyStatistics(for: newYork, spanning: interval, including: .precipitation, .temperature)