def score2A(sim, est):
    return score2A_base(sim.U, np.argmax(est.qun, axis=1))
def score2A(sim, data_df):
    true_df = sim._get_data_df()
    ordered_loci_table = pd.merge(true_df, data_df, on='mutation_id')
    return score2A_base(sim.U, ordered_loci_table.cluster_id)
def score2A(sim, loci_table):
    return score2A_base(sim.U, loci_table.cluster_id)
Exemple #4
0
def score2A(sim, loci_table):
    true_df = sim._get_data_df()
    return score2A_base(sim.U, loci_table.Cluster_Assignment)
 else:
     row_list.append(np.nan)
 if phi_pred_values is not None:
     row_list.append(
         score1C_base(phi_true_values, phi_pred_values, weights_true,
                      weights_pred))
 else:
     row_list.append(np.nan)
 if pred_cluster_assign is not None:
     ordered_table = pd.merge(pred_cluster_assign,
                              true_cluster_assign,
                              on='mutation_id',
                              how='inner')
     if len(true_cluster_assign) < 20000:
         row_list.append(
             score2A_base(ordered_table.true_cluster_id,
                          ordered_table.pred_cluster_id))
     else:
         row_list.append(np.nan)
     ordered_table = pd.merge(pred_subclonal,
                              true_subclonal,
                              on='mutation_id',
                              how='inner')
     auc, accuracy, sensitivity, specificity, precision = \
         score2C_base(ordered_table.true_subclonal,
                      ordered_table.pred_subclonal)
     for v in (auc, accuracy, sensitivity, specificity, precision):
         row_list.append(v)
 else:
     for i in range(6):
         row_list.append(np.nan)
 if pred_profile is not None:
Exemple #6
0
def score2A(sim, data_df):
    return score2A_base(sim.U, data_df.clonality_binary)
def score2A(data_df):
    return score2A_base(data_df.clone, data_df.cluster_id)
 row_list.append(ll_ratio)
 row_list.append(pval)
 if J_pred is not None:
     row_list.append(score1B_base(J_true, J_pred))
 else:
     row_list.append(np.nan)
 if phi_pred_values is not None:
     row_list.append(score1C_base(phi_true_values, phi_pred_values,
                                  weights_true, weights_pred))
 else:
     row_list.append(np.nan)
 if pred_cluster_assign is not None:
     ordered_table = pd.merge(pred_cluster_assign, true_cluster_assign,
                              on='mutation_id', how='inner')
     if len(true_cluster_assign)<20000:
         row_list.append(score2A_base(ordered_table.true_cluster_id,
                                      ordered_table.pred_cluster_id))
     else:
         row_list.append(np.nan)
     ordered_table = pd.merge(pred_subclonal, true_subclonal,
                              on='mutation_id', how='inner')
     auc, accuracy, sensitivity, specificity, precision = \
         score2C_base(ordered_table.true_subclonal,
                      ordered_table.pred_subclonal)
     for v in (auc, accuracy, sensitivity, specificity, precision):
         row_list.append(v)
 else:
     for i in range(6):
         row_list.append(np.nan)
 if pred_profile is not None:
     row_list.append(score_sig_1A_base(sig_profile_1A, pred_profile))
     row_list.append(score_sig_1B_base(sig_profile_1B, pred_profile))
Exemple #9
0
def score2A(sim, loci_table):
    true_df = sim._get_data_df()
    return score2A_base(sim.U, loci_table.cluster)