NEWS


flightanalysis 3.0.0

Breaking Changes

Rationale

This change simplifies the API by enforcing a consistent workflow:

  1. Create queries with fa_define_query() or fa_define_query_range()
  2. Fetch data with fa_fetch_flights() to get flight_results objects
  3. Analyze data with processing functions

flightanalysis 2.1.0

API Improvements

Breaking Changes

New Features

Enhancements

Example

# Create queries for multiple origins
queries <- fa_define_query_range(
  origin = c("BOM", "DEL"),
  dest = "JFK",
  date_min = "2025-12-18",
  date_max = "2025-12-22"
)

# Fetch data - returns flight_results object with merged data
flights <- fa_fetch_flights(queries)

# Access merged data directly
flights$data

# Or access individual origin data
flights$BOM$data
flights$DEL$data

# Use with analysis functions
fa_summarize_prices(flights)
fa_find_best_dates(flights, n = 5)

flightanalysis 2.0.0

Major API Redesign

This release represents a complete redesign of the package API following Tidyverse conventions with consistent fa_ prefixing for all user-facing functions.

Core Functions

Query Creation:

Data Fetching:

Analysis Functions:

Example Usage

library(flightanalysis)

# Create a query
query <- fa_define_query("JFK", "IST", "2025-12-20", "2025-12-27")

# Fetch flight data
result <- fa_fetch_flights(query)

# Analyze results
summary <- fa_summarize_prices(result)
best <- fa_find_best_dates(result, n = 5)

Date Range Search

# Search multiple origins over a date range
queries <- fa_define_query_range(
  origin = c("BOM", "DEL", "VNS"),
  dest = "JFK",
  date_min = "2025-12-18",
  date_max = "2026-01-05"
)

# Fetch data for each origin
for (code in names(queries)) {
  queries[[code]] <- fa_fetch_flights(queries[[code]])
}

# Analyze all results
summary <- fa_summarize_prices(queries)
best_dates <- fa_find_best_dates(queries, n = 10, by = "mean")

Internal Functions

The following functions are internal and not exported:

Package Organization

flightanalysis 1.0.0