Create pages/page.py
Browse files- pages/page.py +29 -0
pages/page.py
ADDED
|
@@ -0,0 +1,29 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 1 |
+
import streamlit as st
|
| 2 |
+
import pandas as pd
|
| 3 |
+
|
| 4 |
+
# Introduction and About Data
|
| 5 |
+
st.title("Introduction and About Data")
|
| 6 |
+
st.markdown("""
|
| 7 |
+
Welcome to the Hotel Data Analysis App. This app helps analyze hotel datasets, perform feature engineering,
|
| 8 |
+
and create predictive models. Use the sidebar to navigate through the pages.
|
| 9 |
+
|
| 10 |
+
**Features**:
|
| 11 |
+
- Download the dataset for exploration.
|
| 12 |
+
- Perform exploratory data analysis (EDA) and feature engineering.
|
| 13 |
+
- Create and evaluate machine learning models.
|
| 14 |
+
- Conclude insights from the analysis.
|
| 15 |
+
|
| 16 |
+
**About the Data**:
|
| 17 |
+
The dataset includes hotel-related information such as price, ratings, discounts, cashback, and categories.
|
| 18 |
+
It is designed for understanding relationships between features and building predictive models.
|
| 19 |
+
""")
|
| 20 |
+
|
| 21 |
+
st.markdown("### Download the Dataset")
|
| 22 |
+
sample_data = {
|
| 23 |
+
"Price": [1000, 2000, 1500, 3000],
|
| 24 |
+
"Rating": [4.5, 4.0, 4.2, 3.8],
|
| 25 |
+
"Category": ["Luxury", "Premium", "Budget", "Low Budget"]
|
| 26 |
+
}
|
| 27 |
+
df = pd.DataFrame(sample_data)
|
| 28 |
+
csv = df.to_csv(index=False).encode('utf-8')
|
| 29 |
+
st.download_button("Download Sample Dataset", data=csv, file_name="hotel_data.csv", mime="text/csv")
|