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

Get custom Needleman Wunsch alignment matrix location #353

Draft
wants to merge 1 commit into
base: master
Choose a base branch
from

Conversation

Colelyman
Copy link
Contributor

@kclem is there a particular reason why this alignment matrix can't be customized?

@kclem
Copy link
Member

kclem commented Nov 17, 2023

The problem is that _ROOT is dynamic at runtime depending on where the package is installed, and the EDNAFULL matrix file is placed there during installation. This works for the arg default 'EDNAFULL', but if we prepend args.needleman_wunsch_aln_matrix_loc by ROOT, that won't produce a valid path for users who specify their own file.

Some other options would be:

  1. have args.needleman_wunsch_aln_matrix_loc default to None, and if at runtime the arg is None, we look for the EDNAFULL in _ROOT. However, this may be confusing to users ("The default value is None?!?") although we could potentially compassionately deceive users by telling them the default is ENDAFULL and have the default really be None
  2. get rid of the EDNAFULL matrix file and just recreate it in memory

@Colelyman
Copy link
Contributor Author

Ah, I see what it is like that now; I figured there was a good reason :).

  1. I like this option because it keeps the file separate which makes it easier to modify. Also, if a user wants a custom matrix, but doesn't want to supply --needleman_wunsch_aln_matrix with every run, they can just modify the EDNAFULL file, et voila. (They would need to update it with each install, so it wouldn't be very practical... but I think it is more transparent?)
  2. Not a bad idea either, the only drawback I see is that it makes it slightly more difficult for a user to know how to format a custom matrix file.

Any opposition to me implementing the first option?

@Colelyman
Copy link
Contributor Author

On second thought, isn't this line only executed at runtime (it is inside the main function)? So we should be able to use args.needleman_wunsch_aln_matrix_loc, unless I'm missing something.

@Colelyman Colelyman marked this pull request as draft April 10, 2024 15:50
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.

2 participants