Create README.md
Browse files
README.md
ADDED
|
@@ -0,0 +1,150 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 1 |
+
# Airline Delay Analysis Database
|
| 2 |
+
|
| 3 |
+
`airline_delay_analysis.db` is a SQLite database that integrates airline operation data, airport metadata, weather conditions, fuel prices, and stock performance to support comprehensive analysis of flight delays in the United States.
|
| 4 |
+
|
| 5 |
+
It contains the following tables:
|
| 6 |
+
|
| 7 |
+
1. `Airline` – core flight-level data
|
| 8 |
+
2. `Airports` – airport metadata
|
| 9 |
+
3. `Carriers` – airline company information
|
| 10 |
+
4. `Weather` – daily weather per city
|
| 11 |
+
5. `FuelPrice` – daily jet fuel price
|
| 12 |
+
6. `FuelIndex` – normalized fuel price index
|
| 13 |
+
7. `StockPrice` – airline-related stock data
|
| 14 |
+
|
| 15 |
+
---
|
| 16 |
+
|
| 17 |
+
# 1. Airline Table
|
| 18 |
+
|
| 19 |
+
Primary table containing one row per scheduled or operated flight.
|
| 20 |
+
|
| 21 |
+
## Location and Identification Columns
|
| 22 |
+
|
| 23 |
+
| Column | Description |
|
| 24 |
+
| ------------------- | -------------------------------------- |
|
| 25 |
+
| `airline_id` | Internal unique row ID. |
|
| 26 |
+
| `FL_DATE` | Flight date. |
|
| 27 |
+
| `OP_UNIQUE_CARRIER` | Airline carrier code (e.g., AA, DL). |
|
| 28 |
+
| `OP_CARRIER_FL_NUM` | Flight number assigned by the carrier. |
|
| 29 |
+
| `ORIGIN_AIRPORT_ID` | Numeric ID for origin airport. |
|
| 30 |
+
| `ORIGIN` | Origin airport IATA code. |
|
| 31 |
+
| `ORIGIN_CITY_NAME` | Origin city name. |
|
| 32 |
+
| `ORIGIN_STATE_ABR` | State abbreviation. |
|
| 33 |
+
| `ORIGIN_STATE_FIPS` | FIPS state code. |
|
| 34 |
+
| `ORIGIN_STATE_NM` | Full state name. |
|
| 35 |
+
| `ORIGIN_WAC` | World Area Code for origin. |
|
| 36 |
+
| `DEST_AIRPORT_ID` | Destination airport ID. |
|
| 37 |
+
| `DEST` | Destination airport IATA code. |
|
| 38 |
+
| `DEST_CITY_NAME` | Destination city name. |
|
| 39 |
+
| `DEST_STATE_ABR` | Destination state abbreviation. |
|
| 40 |
+
| `DEST_STATE_FIPS` | Destination state FIPS code. |
|
| 41 |
+
| `DEST_STATE_NM` | Destination state name. |
|
| 42 |
+
| `DEST_WAC` | World Area Code for destination. |
|
| 43 |
+
| `CRS_DEP_TIME` | Scheduled departure time (HHMM). |
|
| 44 |
+
| `DEP_TIME` | Actual departure time (HHMM). |
|
| 45 |
+
| `DEP_DELAY` | Actual departure delay in minutes. |
|
| 46 |
+
| `DEP_DELAY_NEW` | Departure delay with negative values clipped to zero. |
|
| 47 |
+
| `DEP_DEL15` | 1 if departure delay is 15 minutes or more. |
|
| 48 |
+
| `DEP_DELAY_GROUP` | Delay group category (15-minute bins). |
|
| 49 |
+
| `DEP_TIME_BLK` | Scheduled departure time block (e.g., "0600-0659"). |
|
| 50 |
+
| `CRS_ARR_TIME` | Scheduled arrival time. |
|
| 51 |
+
| `ARR_TIME` | Actual arrival time. |
|
| 52 |
+
| `ARR_DELAY` | Actual arrival delay in minutes. |
|
| 53 |
+
| `ARR_DEL15` | 1 if arrival delay is 15 minutes or more. |
|
| 54 |
+
| `ARR_DELAY_GROUP` | Arrival delay group category. |
|
| 55 |
+
| `ARR_TIME_BLK` | Scheduled arrival time block. |
|
| 56 |
+
| `CANCELLED` | 1 if the flight was canceled. |
|
| 57 |
+
| `CANCELLATION_CODE` | Reason code (A=Carrier, B=Weather, C=NAS, D=Security). |
|
| 58 |
+
| `DIVERTED` | 1 if the flight diverted to another airport. |
|
| 59 |
+
| `CRS_ELAPSED_TIME` | Scheduled elapsed time in minutes. |
|
| 60 |
+
| `ACTUAL_ELAPSED_TIME` | Actual elapsed time in minutes. |
|
| 61 |
+
| `AIR_TIME` | Time spent in the air. |
|
| 62 |
+
| `FLIGHTS` | Number of flights (usually 1). |
|
| 63 |
+
| `DISTANCE` | Flight distance in miles. |
|
| 64 |
+
| `DISTANCE_GROUP` | Distance category (50-mile bins). |
|
| 65 |
+
| `CARRIER_DELAY` | Delay caused by airline operations. |
|
| 66 |
+
| `WEATHER_DELAY` | Delay caused by weather conditions. |
|
| 67 |
+
| `NAS_DELAY` | Delay caused by the National Airspace System. |
|
| 68 |
+
| `SECURITY_DELAY` | Delay caused by security issues. |
|
| 69 |
+
| `LATE_AIRCRAFT_DELAY` | Delay caused by previous aircraft arriving late. |
|
| 70 |
+
| `DEP_DELAY_OVER15` | 1 if departure delay ≥ 15 minutes. |
|
| 71 |
+
| `ARR_DELAY_OVER15` | 1 if arrival delay ≥ 15 minutes. |
|
| 72 |
+
| `TOTAL_DELAY` | Combined total delay. |
|
| 73 |
+
| `ANY_DELAY` | 1 if any delay condition is present. |
|
| 74 |
+
|
| 75 |
+
---
|
| 76 |
+
|
| 77 |
+
# 2. Airports Table
|
| 78 |
+
|
| 79 |
+
| Column | Description |
|
| 80 |
+
| -------------- | -------------------- |
|
| 81 |
+
| `airport_id` | Unique airport ID. |
|
| 82 |
+
| `airport_code` | Airport IATA code. |
|
| 83 |
+
| `city_name` | City of the airport. |
|
| 84 |
+
| `state_abbr` | State abbreviation. |
|
| 85 |
+
| `state_name` | Full state name. |
|
| 86 |
+
|
| 87 |
+
---
|
| 88 |
+
|
| 89 |
+
# 3. Carriers Table
|
| 90 |
+
|
| 91 |
+
| Column | Description |
|
| 92 |
+
| -------------- | ---------------------- |
|
| 93 |
+
| `iata_code` | Airline code. |
|
| 94 |
+
| `carrier_name` | Official airline name. |
|
| 95 |
+
|
| 96 |
+
---
|
| 97 |
+
|
| 98 |
+
# 4. Weather Table
|
| 99 |
+
|
| 100 |
+
| Column | Description |
|
| 101 |
+
| ------------ | --------------------------------- |
|
| 102 |
+
| `date` | Date of weather record. |
|
| 103 |
+
| `t2m` | Temperature at 2 meters (Kelvin). |
|
| 104 |
+
| `v10` | Wind speed at 10 meters. |
|
| 105 |
+
| `snc` | Snow cover percentage. |
|
| 106 |
+
| `sde` | Snow depth equivalent. |
|
| 107 |
+
| `city_name` | City name. |
|
| 108 |
+
| `state_abbr` | State abbreviation. |
|
| 109 |
+
| `state_name` | Full state name. |
|
| 110 |
+
| `lat` | Latitude. |
|
| 111 |
+
| `lng` | Longitude. |
|
| 112 |
+
| `t2m_C` | Temperature in Celsius. |
|
| 113 |
+
|
| 114 |
+
---
|
| 115 |
+
|
| 116 |
+
# 5. FuelPrice Table
|
| 117 |
+
|
| 118 |
+
| Column | Description |
|
| 119 |
+
| ---------------- | ---------------------- |
|
| 120 |
+
| `date` | Date of record. |
|
| 121 |
+
| `jet_fuel_price` | Jet fuel price in USD. |
|
| 122 |
+
|
| 123 |
+
---
|
| 124 |
+
|
| 125 |
+
# 6. FuelIndex Table
|
| 126 |
+
|
| 127 |
+
| Column | Description |
|
| 128 |
+
| ---------------- | ---------------------------- |
|
| 129 |
+
| `date` | Date of index. |
|
| 130 |
+
| `jet_fuel_index` | Normalized fuel index value. |
|
| 131 |
+
|
| 132 |
+
---
|
| 133 |
+
|
| 134 |
+
# 7. StockPrice Table
|
| 135 |
+
|
| 136 |
+
| Column | Description |
|
| 137 |
+
| ------------------- | -------------------------------------- |
|
| 138 |
+
| `stock_price_id` | Unique row ID. |
|
| 139 |
+
| `date` | Trading date. |
|
| 140 |
+
| `price` | Closing price. |
|
| 141 |
+
| `open_price` | Opening price. |
|
| 142 |
+
| `high_price` | Highest trading price. |
|
| 143 |
+
| `low_price` | Lowest trading price. |
|
| 144 |
+
| `volume` | Number of shares traded. |
|
| 145 |
+
| `change_percentage` | Percentage change from previous close. |
|
| 146 |
+
| `company_name` | Company or ETF name. |
|
| 147 |
+
| `iata_code` | Airline code (if applicable). |
|
| 148 |
+
|
| 149 |
+
---
|
| 150 |
+
|