A simple R Shiny application for exploring CSV data with two main features:
- Data Table Tab: Upload and view CSV files in an interactive table
- Time Series Plot Tab: Create interactive time series visualizations
- Upload CSV files with customizable parsing options (separator, quote, header)
- Interactive data table with sorting and filtering
- Data summary showing row count, column count, and column names
- Automatic detection of date and numeric columns
- Interactive plotly charts with zoom and hover functionality
- Date range filtering
- Optional trend line overlay
- Responsive design
Make sure you have the following R packages installed:
install.packages(c("shiny", "DT", "ggplot2", "plotly"))- Open R or RStudio
- Set your working directory to this folder:
setwd("c:/Users/username/Desktop/portal") - Run the app:
shiny::runApp("app.R")
Alternatively, you can run it directly:
source("app.R")-
Loading Data:
- Go to the "Data Table" tab
- Click "Choose CSV File" and select your CSV file
- Adjust parsing options if needed (separator, quotes, header)
- View your data in the interactive table
-
Creating Time Series Plots:
- After loading data, go to the "Time Series Plot" tab
- Select the date column and value column from the dropdowns
- Adjust the date range if needed
- Optionally add a trend line
- Interact with the plot (zoom, hover, etc.)
app.R- Main Shiny application filedata.csv- Sample data file (if present)README.md- This documentation file
- The app automatically tries to detect date columns by looking for common date patterns
- If no date columns are detected, all columns will be available for selection
- The app handles various CSV formats and provides error handling for plotting issues
- All plots are interactive thanks to the plotly integration