The HelloData API returns raw property data, giving you the freedom to aggregate and analyze it according to your needs. This guide shows you how to compute common metrics like average effective rent, occupancy, and price per square foot (PSF) from the /property/{id} response.
All examples assume you have a PropertyDetailsResponse object from GET /property/{id}. See the Property Details guide for how to fetch this data.
Before computing any metrics, you need to filter units correctly:
is_floorplan: true) and actual units, only use the actual units for calculations.price, effective_price, sqft) which represent the latest values. For historical calculations, use the history array.Average effective rent is the mean of all unit effective rents (price after discounts/concessions).
Formula: Average of effective_price or min_effective_price (if effective_price is null) for all valid units.
Average asking rent is the mean of all unit asking rents (advertised price before discounts).
Formula: Average of price or min_price (if price is null) for all valid units.
Average square footage is the mean of all unit sizes.
Formula: Average of sqft or min_sqft (if sqft is null) for all valid units.
Important: PSF must be calculated as a weighted average, not as the average of individual unit PSF values.
Formula: sum(all_effective_prices) / sum(all_sqfts)
This gives you the true average PSF, accounting for unit size differences. Calculating average(price/sqft) would incorrectly weight all units equally regardless of size.
Same as effective PSF, but using asking prices instead.
Formula: sum(all_asking_prices) / sum(all_sqfts)
Concessions are discounts or promotions that reduce the effective rent below the asking rent.
Formula: Average of (asking_price - effective_price) for all units with both values.
Occupancy represents the percentage of units that are leased (not available for rent). This is a simplified calculation for a specific date. For time-series occupancy data, you would need to analyze availability_periods over time.
Formula: (total_units - available_units) / total_units * 100
This simplified calculation assumes number_units from the property represents the total unit count. For lease-up properties or more accurate calculations, you may need to use the occupancyOverTime function logic which considers when units entered/exited the market.
Here’s a complete example that computes all metrics at once:
Always filter floorplans: When a property has both floorplans and actual units, use only the actual units for calculations.
Handle null values: Filter out null values before computing averages. Use fallback values (min_price, min_effective_price, min_sqft) when the primary field is null.
PSF is weighted: Always calculate PSF as sum(prices) / sum(sqfts), not average(price/sqft). This accounts for unit size differences.
Use top-level fields for current values: The price, effective_price, and sqft fields represent the latest values. For historical analysis, use the history array.
Occupancy is complex: The simplified occupancy calculation above works for a single date. For accurate time-series occupancy, you need to analyze availability_periods over time, considering when units enter/exit the market.
These calculations match what you see on the HelloData platform. If your results differ, check that you’re filtering units correctly and handling null values as shown above.