Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Add script to download methyl files #415

Merged
merged 7 commits into from
Jul 17, 2023
Merged

Add script to download methyl files #415

merged 7 commits into from
Jul 17, 2023

Conversation

zzgeng
Copy link

@zzgeng zzgeng commented Jul 10, 2023

Purpose/implementation Section

What scientific question is your analysis addressing?

Add script to download v13 methylation-related files from AWS

What was your approach?

add download_methyl.sh in script folder.

What GitHub issue does your pull request address?

Directions for reviewers. Tell potential reviewers what kind of feedback you are soliciting.

Which areas should receive a particularly close look?

script/download_methyl.sh

Is there anything that you want to discuss further?

No

Is the analysis in a mature enough form that the resulting figure(s) and/or table(s) are ready for review?

Results

What types of results are included (e.g., table, figure)?

bash script

What is your summary of the results?

Reproducibility Checklist

  • The dependencies required to run the code in this pull request have been added to the project Dockerfile.
  • This analysis has been added to continuous integration.

Documentation Checklist

  • This analysis module has a README and it is up to date.
  • This analysis is recorded in the table in analyses/README.md and the entry is up to date.
  • The analytical code is documented and contains comments.

@zzgeng zzgeng requested a review from jharenza July 10, 2023 19:48
Copy link
Member

@jharenza jharenza left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Few notes:

  1. If directory does not exist, this will fail. Can you add a chunk to check?
  2. Can you make the script name download-methyl.sh with hyphen to conform to other script names?
  3. Can you add a bit in the readme about this new script, what it is, how to download?

@zzgeng zzgeng mentioned this pull request Jul 14, 2023
5 tasks
@jharenza jharenza requested review from jharenza and rjcorb July 14, 2023 17:56
@jharenza
Copy link
Member

@rjcorb I made some updates, can you test this on your end, esp since you do not have v13 on your computer currently?

@rjcorb
Copy link

rjcorb commented Jul 17, 2023

@zzgeng @jharenza this runs fine when run within the scripts directory. But there are inconsistencies in which directories different scripts/ bash files need to be run from. For example, download-testing-files.sh needs to be run from root and not scripts/. I think following the code in scripts/generate-analysis-files.sh would allow this to be run from any directory:

# Set the working directory to the directory of this file
cd "$(dirname "${BASH_SOURCE[0]}")"

# If RUN_LOCAL is used, the time-intensive steps are skipped because they cannot
# be run on a local computer -- the idea is that setting RUN_LOCAL=1 will allow for
# local testing running/testing of all other steps
RUN_LOCAL=${RUN_LOCAL:-0}

# Get base directory of project
cd ..
BASEDIR="$(pwd)"
cd -

Copy link

@rjcorb rjcorb left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

See above comment

@zzgeng
Copy link
Author

zzgeng commented Jul 17, 2023

@zzgeng @jharenza this runs fine when run within the scripts directory. But there are inconsistencies in which directories different scripts/ bash files need to be run from. For example, download-testing-files.sh needs to be run from root and not scripts/. I think following the code in scripts/generate-analysis-files.sh would allow this to be run from any directory:

# Set the working directory to the directory of this file
cd "$(dirname "${BASH_SOURCE[0]}")"

# If RUN_LOCAL is used, the time-intensive steps are skipped because they cannot
# be run on a local computer -- the idea is that setting RUN_LOCAL=1 will allow for
# local testing running/testing of all other steps
RUN_LOCAL=${RUN_LOCAL:-0}

# Get base directory of project
cd ..
BASEDIR="$(pwd)"
cd -

That's a very good suggestion! I've made changes accordingly. Thank you!

@rjcorb rjcorb self-requested a review July 17, 2023 16:20
@jharenza
Copy link
Member

Agree- Thanks @rjcorb

@jharenza jharenza merged commit e119732 into dev Jul 17, 2023
1 of 2 checks passed
@jharenza jharenza deleted the methyl_download branch July 17, 2023 17:13
This pull request was closed.
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants