Skip to content

Conversation

jkgoodrich
Copy link
Contributor

Currently this will result in an error at this line:

pc_cols = [f"PC{i}" for i in pc_cols]

because pc_cols is a Hail ArrayExpression.

Copy link
Contributor

@mike-w-wilson mike-w-wilson left a comment

Choose a reason for hiding this comment

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

One small thing but then LGTM

pc_expr = pop_pca_scores[pc_expr]
pcs_to_pull = [pc_expr[i - 1] for i in pc_cols]
else:
pc_col_len = list(
Copy link
Contributor

Choose a reason for hiding this comment

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

I think filter already returns a list so the cast is not needed

Copy link
Contributor Author

Choose a reason for hiding this comment

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

Hmm, I think it gave me an error, I will try again and make sure

Copy link
Contributor Author

Choose a reason for hiding this comment

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

TypeError: object of type 'filter' has no len()

@jkgoodrich jkgoodrich merged commit 159e5a7 into main Nov 8, 2022
@jkgoodrich jkgoodrich deleted the jg/assign_population_pcs_pc_cols_name_fix branch November 8, 2022 14:32
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants