This Flask web application allows users to compare inventory data from the North Carolina Alcoholic Beverage Control (NC ABC) between two selected dates, perform advanced data analysis, and analyze brand-specific inventory trends. Users can filter results based on a specific supplier, view inventory changes over time, and analyze data through various graphical representations including predictive analytics for brand availability.
- Compare inventory data between two dates.
- Option to filter comparison by a specific supplier.
- Visual display of inventory changes: new items, removed items, and quantity changes.
- Advanced data analysis with interactive graphs, including:
- Inventory levels over time.
- Brand-wise inventory distribution.
- Inventory size distribution.
- Supplier contribution to inventory.
- Top 15 brands by total volume in milliliters.
- Brand-specific analysis with predictive trends:
- Interactive brand selector with multi-select and type-ahead features.
- Predictive graphs showing historical and projected inventory levels for selected brands.
- Insights to anticipate when specific brands will be available on local shelves.
To set up this project on your local machine, follow these steps:
-
Clone the Repository
gh repo clone swiftraccoon/ncABC cd ncABC
-
Install Dependencies
Ensure you have Python installed on your system. Then install the required Python packages:
python3 -m venv ncABC source ncABC/bin/activate pip install -r web/requirements.txt
-
Environment Variables
Check the
.env
files inweb
anddata_management
if you're modifying how the project is setup. -
Generate the Database
Before you can run the application you must first build the database.
To do this, run these commands:
cd data_management python data_management.py python historical_insert.py
You should now have a
data_management/inventory.db
-
Running the Application
To run the application, execute:
python app.py
Visit
http://localhost:5000
in your web browser to view the main application.
- On the home page, select two dates for which you want to compare inventory data.
- Optionally, specify a supplier to filter the comparison.
- Submit the form to view the comparison results.
- Access the advanced analysis section to view interactive graphs and insights into the inventory data.
- Use the brand-specific analysis feature to select one or multiple brands and view predictive trends and availability insights.
Contributions to this project are welcome. Please follow these steps to contribute:
- Fork the repository.
- Create a new branch for your feature (
git checkout -b feature/AmazingFeature
). - Commit your changes (
git commit -m 'Add some AmazingFeature'
). - Push to the branch (
git push origin feature/AmazingFeature
). - Open a pull request.
Distributed under the GPL3 License. See LICENSE
for more information.