-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Fix title padding, increase button sizes, and improve R script
- Loading branch information
Showing
6 changed files
with
26 additions
and
11 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,5 +1,5 @@ | ||
{ | ||
"snippet1": "# Load the 'dplyr' package. If it's not installed, run install.packages(\"dplyr\")\nlibrary(dplyr)\n\n# (Optional) Set your working directory\nsetwd(\"/path_to/your_working_directory\")\n\n# Read your data into a data frame\ndf1 <- read.csv(\"/path_to/your_data_file.csv\", header = T)\n\n# Read the downloaded Data Commons CSV file into a new data frame\ndf2 <- read.csv(\"/path_to/dcw_data.csv\", header=T)\n\n# Merge the two data frames using the appropriate column names\ncol1 = \"zip\"\ncol2 = \"zipCode\"\nmerged_df <- left_join(df1, df2, by=setNames(nm=col1, col2))\n\n# (Optional) Export merged data to CSV\nwrite.csv(merged_df, \"/path_to/merged_data.csv\", row.names = F)" | ||
"snippet1": "# Please fill in the following constants according to your folder/file names\nwd <- \"~/Desktop/r_wd\"\nuser_filename <- \"user_data.csv\"\ndcw_filename <- \"dcw_data.csv\"\nuser_colname = \"zip\"\ndcw_colname = \"zipCode\"\noutput_filename <- \"merged_data.csv\"\n\n# Load the 'dplyr' package. If it's not installed, run install.packages(\"dplyr\")\nlibrary(dplyr)\n\n# Set working directory\nsetwd(wd)\n\n# Read the user's data\ndf1 <- read.csv(user_filename, header = T)\n\n# Read the downloaded Data Commons CSV file into a new data frame\ndf2 <- read.csv(dcw_filename, header=T)\n\n# Merge the two data frames using the appropriate column names\nmerged_df <- left_join(df1, df2, by=setNames(nm=user_colname, dcw_colname))\n\n# Export merged data to CSV\nwrite.csv(merged_df, output_filename, row.names = F)" | ||
} | ||
|
||
|
Binary file not shown.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters