Skip to content

Commit

Permalink
remove sample_class_filter
Browse files Browse the repository at this point in the history
  • Loading branch information
danlu1 committed Nov 23, 2024
1 parent a757ad7 commit a84810b
Show file tree
Hide file tree
Showing 2 changed files with 1 addition and 22 deletions.
5 changes: 1 addition & 4 deletions genie/consortium_to_public.py
Original file line number Diff line number Diff line change
Expand Up @@ -3,9 +3,8 @@
import logging
import os

import synapseutils
import pandas as pd

import synapseutils
from genie import (
create_case_lists,
database_to_staging,
Expand Down Expand Up @@ -119,8 +118,6 @@ def consortiumToPublic(
clinicalDf, processingDate, publicReleaseCutOff
)
logger.info("SAMPLE CLASS FILTER")
remove_sc_samples = database_to_staging.sample_class_filter(clinical_df=clinicalDf)
removeForPublicSamples = list(set(removeForPublicSamples).union(remove_sc_samples))
# comment back in when public release filter back on
# publicReleaseSamples = publicReleaseSamples.append(keepForPublicSamples)
# Make sure all null oncotree codes are removed
Expand Down
18 changes: 0 additions & 18 deletions genie/database_to_staging.py
Original file line number Diff line number Diff line change
Expand Up @@ -555,24 +555,6 @@ def seq_date_filter(clinicalDf, processingDate, consortiumReleaseCutOff):
return removeSeqDateSamples


def sample_class_filter(clinical_df: pd.DataFrame) -> list:
"""Filter samples by SAMPLE_CLASS
Args:
clinical_df (pd.DataFrame): Clinical dataframe
Returns:
list: List of samples to filter out
"""
if clinical_df.get("SAMPLE_CLASS") is not None:
remove_samples = clinical_df["SAMPLE_ID"][
clinical_df["SAMPLE_CLASS"] == "cfDNA"
].tolist()
else:
remove_samples = []
return remove_samples


# TODO: Add to transform.py
def mutation_in_cis_filter(
syn,
Expand Down

0 comments on commit a84810b

Please sign in to comment.