Commit 1c86fd1a authored by Sayed Rzgar Hosseini's avatar Sayed Rzgar Hosseini
Browse files

Upload New File

parent ef35cf89
######################################################################################################################################################################################################
anchor_breast<-read.csv("./Tables/Table10.csv")$Gene
anchor_colorectal<-read.csv("./Tables/Table11.csv")$Gene
Candidate_Breast<-read.csv("./Tables/Table8.csv")$x
Candidate_Colorectal<-read.csv("./Tables/Table9.csv")$x
######################################################################################################################################################################################################
######################################################################################################################################################################################################
ANOVA_BREAST<-read.csv("./Tables/Table18.csv") #GDSC Data (Breast)
ANOVA_COLO<-read.csv("./Tables/Table19.csv") #GDSC Data (Colorectal)
# Selecting biomarkers of drug sensitivity and resistance (Breast)
B1<-intersect(which(ANOVA_BREAST$FEATURE_neg_Glass_delta>1),which(ANOVA_BREAST$FEATURE_pos_Glass_delta>1))
B2<-which(ANOVA_BREAST$ANOVA_FEATURE_FDR<25)
B3<-which(ANOVA_BREAST$FEATURE_IC50_T_pval<0.01)
B<-intersect(intersect(B1,B2),B3) # Set of selected features (Breast)
upsB<-numeric(length(B))
mutB<-numeric(length(B))
for (i in 1:length(B)){
upsB[i]<-grepl("_up",ANOVA_BREAST$FEATURE[B[i]])
mutB[i]<-grepl("_mut",ANOVA_BREAST$FEATURE[B[i]])
}
B<-B[which((upsB+mutB)>0)]# considering only the upregulated and mutation features
# Selecting biomarkers of drug sensitivity and resistance (Colorectal)
C1<-intersect(which(ANOVA_COLO$FEATURE_neg_Glass_delta>1),which(ANOVA_COLO$FEATURE_pos_Glass_delta>1))
C2<-which(ANOVA_COLO$ANOVA_FEATURE_FDR<25)
C3<-which(ANOVA_COLO$FEATURE_IC50_T_pval<0.01)
C<-intersect(intersect(C1,C2),C3) # Set of selected features (Colorectal)
upsC<-numeric(length(C))
mutC<-numeric(length(C))
for (i in 1:length(C)){
upsC[i]<-grepl("_up",ANOVA_BREAST$FEATURE[C[i]])
mutC[i]<-grepl("_mut",ANOVA_BREAST$FEATURE[C[i]])
}
C<-C[which((upsC+mutC)>0)]# considering only the upregulated and mutation features
# Target names and drugs of the expression and mutation biomarkers (Breast)
INDX_B_UP<-B[grep("_up",ANOVA_BREAST$FEATURE[B])]# Retrieve the indices of the up-regulated expression markers
INDX_B_MUT<-B[grep("_mut",ANOVA_BREAST$FEATURE[B])]# Retrieve the indices of the mutation markers
B_up<-gsub("_up", "",ANOVA_BREAST$FEATURE[INDX_B_UP]) # Expression-based biomarkers
B_mut<-gsub("_mut", "",ANOVA_BREAST$FEATURE[INDX_B_MUT]) # Mutation based biomarkers
BT_UP<-as.character(ANOVA_BREAST$DRUG_TARGET[INDX_B_UP]) # Target names of the Expression-based biomarkers
BT_MUT<-as.character(ANOVA_BREAST$DRUG_TARGET[INDX_B_MUT]) # Target names of the Mutation based biomarkers
DB_UP<-as.character(ANOVA_BREAST$DRUG_NAME.x[INDX_B_UP]) # Drug names of the expression based biomarkers
DB_MUT<-as.character(ANOVA_BREAST$DRUG_NAME.x[INDX_B_MUT]) # Drug names of the Mutation based biomarkers
# Target names and drugs of the expression and mutation biomarkers (Colorectal)
INDX_C_UP<-C[grep("_up",ANOVA_COLO$FEATURE[C])]# Retrieve the indices of the up-regulated expression markers
INDX_C_MUT<-C[grep("_mut",ANOVA_COLO$FEATURE[C])]# Retrieve the indices of the mutation markers
C_up<-gsub("_up", "",ANOVA_COLO$FEATURE[INDX_C_UP]) # Expression-based biomarkers
C_mut<-gsub("_mut", "",ANOVA_COLO$FEATURE[INDX_C_MUT]) # Mutation based biomarkers
CT_UP<-as.character(ANOVA_COLO$DRUG_TARGET[INDX_C_UP]) # Target names of the Expression-based biomarkers
CT_MUT<-as.character(ANOVA_COLO$DRUG_TARGET[INDX_C_MUT]) # Target names of the Mutation based biomarkers
DC_UP<-as.character(ANOVA_COLO$DRUG_NAME.x[INDX_C_UP]) # Drug names of the expression based biomarker
DC_MUT<-as.character(ANOVA_COLO$DRUG_NAME.x[INDX_C_MUT]) # Drug names of the Mutation based biomarkers
#######################################################################################################################################################
# Criteria 1: An anchor gene is a biomarker of resistance to a drug that targets the candidate gene
# Expression based [Breast]
New_Candidates_Breast<-c()
intersect(anchor_breast,B_up) # only: "PARP1"
DB_UP[which(B_up=="PARP1")] # "Nutlin-3a (-)"
sel<-which(as.character(ANOVA_BREAST$DRUG_NAME.x)==DB_UP[which(B_up=="PARP1")]) #Retrieve the rows with the given drug name
sel_set<-strsplit(unique(as.character(ANOVA_BREAST$DRUG_TARGET[sel])),", ")[[1]] #set of targets of the given drug (only "MDM2")
if ((ANOVA_BREAST$FEATURE_pos_logIC50_MEAN[INDX_B_UP[which(B_up=="PARP1")]]-ANOVA_BREAST$FEATURE_neg_logIC50_MEAN[INDX_B_UP[which(B_up=="PARP1")]])>0){# to check whether the marker is "Resistance maker" and not "Sensitivity"
New_Candidates_Breast<-c(New_Candidates_Breast,sel_set)
}
# Mutation based [Breast]
intersect(anchor_breast,B_mut) # only: "PIK3CA"
DB_MUT[which(B_mut=="PIK3CA")] # "Alpelisib" "Taselisib"
sel<-which(as.character(ANOVA_BREAST$DRUG_NAME.x)==DB_MUT[which(B_mut=="PIK3CA")]) #Retrieve the rows with the given drug name
sel_set<-strsplit(unique(as.character(ANOVA_BREAST$DRUG_TARGET[sel])),", ")[[1]] #set of targets of the given drug
if (sum((ANOVA_BREAST$FEATURE_pos_logIC50_MEAN[INDX_B_MUT[which(B_mut=="PIK3CA")]]-ANOVA_BREAST$FEATURE_neg_logIC50_MEAN[INDX_B_MUT[which(B_mut=="PIK3CA")]])>0)>0){# to check whether the marker is "Resistance maker" and not "Sensitivity"
New_Candidates_Breast<-c(New_Candidates_Breast,sel_set)
}
# The above set of conditions doe not retrieve any new candidate for breast library
# Expression based [Colorectal]
New_Candidates_Colorectal<-c()
intersect(anchor_colorectal,C_up) # only: "PTPN11"
setDC<-DC_UP[which(C_up=="PTPN11")] # Nilotinib" "BIBR-1532" "Kobe0065" "AX15836" "VH298"
for (i in 1:length(setDC)){
sel<-which(as.character(ANOVA_COLO$DRUG_NAME.x)==setDC[i]) #Retrieve the rows with the given drug name
sel_set<-strsplit(unique(as.character(ANOVA_COLO$DRUG_TARGET[sel])),", ")[[1]] #set of targets of the given drug
if (sum((ANOVA_COLO$FEATURE_pos_logIC50_MEAN[INDX_C_UP[which(C_up=="PTPN11")]]-ANOVA_COLO$FEATURE_neg_logIC50_MEAN[INDX_C_UP[which(C_up=="PTPN11")]])>0)>0){# to check whether the marker is "Resistance maker" and not "Sensitivity"
New_Candidates_Colorectal<-c(New_Candidates_Colorectal,sel_set)
}
}
intersect(anchor_colorectal,C_mut) # only: "BRAF"
setDC<-DC_MUT[which(C_mut=="BRAF")] # "PLX-4720"
for (i in 1:length(setDC)){
sel<-which(as.character(ANOVA_COLO$DRUG_NAME.x)==setDC[i]) #Retrieve the rows with the given drug name
sel_set<-strsplit(unique(as.character(ANOVA_COLO$DRUG_TARGET[sel])),", ")[[1]] #set of targets of the given drug
print(sel_set)
if (sum((ANOVA_COLO$FEATURE_pos_logIC50_MEAN[INDX_C_MUT[which(C_mut=="BRAF")]]-ANOVA_COLO$FEATURE_neg_logIC50_MEAN[INDX_C_MUT[which(C_mut=="BRAF")]])>0)>0){# to check whether the marker is "Resistance maker" and not "Sensitivity"
New_Candidates_Colorectal<-c(New_Candidates_Colorectal,sel_set)
}
}
#######################################################################################################################################################
#######################################################################################################################################################
# Criteria2: One of the anchor genes must be the target of a drug that targets the candidate gene
# Drug names of the expression based biomarkers [Breast]
for (i in 1:length(DB_UP)){
sel<-which(as.character(ANOVA_BREAST$DRUG_NAME.x)==DB_UP[i]) #Retrieve the rows with the given drug name
sel_set<-strsplit(unique(as.character(ANOVA_BREAST$DRUG_TARGET[sel])),", ")[[1]] #set of targets of the given drug
print(sel_set)
if (length(intersect(anchor_breast,sel_set))>0){ # to check if the drug targets at least one anchor gene
if ((ANOVA_BREAST$FEATURE_pos_logIC50_MEAN[INDX_B_UP[i]]-ANOVA_BREAST$FEATURE_neg_logIC50_MEAN[INDX_B_UP[i]])>0){# to check whether the marker is "Resistance maker" and not "Sensitivity"
New_Candidates_Breast<-c(New_Candidates_Breast,B_up[i])
}
}
}
# Drug names of the mutation based biomarkers [Breast]
for (i in 1:length(DB_MUT)){
sel<-which(as.character(ANOVA_BREAST$DRUG_NAME.x)==DB_MUT[i]) #Retrieve the rows with the given drug name
sel_set<-strsplit(unique(as.character(ANOVA_BREAST$DRUG_TARGET[sel])),", ")[[1]] #set of targets of the given drug
print(sel_set)
if (length(intersect(anchor_breast,sel_set))>0){ # to check if the drug targets at least one anchor gene
if ((ANOVA_BREAST$FEATURE_pos_logIC50_MEAN[INDX_B_MUT[i]]-ANOVA_BREAST$FEATURE_neg_logIC50_MEAN[INDX_B_MUT[i]])>0){# to check whether the marker is "Resistance maker" and not "Sensitivity"
New_Candidates_Breast<-c(New_Candidates_Breast,B_mut[i])
}
}
}
# The above set of conditions doe not retrieve any new candidate for breast library
# Drug names of the expression based biomarkers [Colorectal]
New_Candidates_Colorectal<-c()
for (i in 1:length(DC_UP)){
sel<-which(as.character(ANOVA_COLO$DRUG_NAME.x)==DC_UP[i]) #Retrieve the rows with the given drug name
sel_set<-strsplit(unique(as.character(ANOVA_COLO$DRUG_TARGET[sel])),", ")[[1]] #set of targets of the given drug
print(sel_set)
if (length(intersect(anchor_colorectal,sel_set))>0){ # to check if the drug targets at least one anchor gene
if ((ANOVA_COLO$FEATURE_pos_logIC50_MEAN[INDX_C_UP[i]]-ANOVA_COLO$FEATURE_neg_logIC50_MEAN[INDX_C_UP[i]])>0){# to check whether the marker is "Resistance maker" and not "Sensitivity"
New_Candidates_Colorectal<-c(New_Candidates_Colorectal,C_up[i])
}
}
}
# Drug names of the mutation based biomarkers [Colorectal]
for (i in 1:length(DC_MUT)){
sel<-which(as.character(ANOVA_COLO$DRUG_NAME.x)==DC_MUT[i]) #Retrieve the rows with the given drug name
sel_set<-strsplit(unique(as.character(ANOVA_COLO$DRUG_TARGET[sel])),", ")[[1]] #set of targets of the given drug
print(sel_set)
if (length(intersect(anchor_colorectal,sel_set))>0){ # to check if the drug targets at least one anchor gene
if ((ANOVA_COLO$FEATURE_pos_logIC50_MEAN[INDX_C_MUT[i]]-ANOVA_COLO$FEATURE_neg_logIC50_MEAN[INDX_C_MUT[i]])>0){# to check whether the marker is "Resistance maker" and not "Sensitivity"
New_Candidates_Colorectal<-c(New_Candidates_Colorectal,C_mut[i])
}
}
}
unique(New_Candidates_Breast) # nothing
unique(New_Candidates_Colorectal) # "MAP3K1" "RHEB" "DLG1"
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment