Commit 783fa4d7 authored by Marcel Henrik Schubert's avatar Marcel Henrik Schubert
Browse files

split feature plot apart

parent 414e2f9d
......@@ -946,12 +946,12 @@ def plotter(subsets, subana, phases, labels):
half = math.floor(len(df.index)/2)
sub = df[0:half]
f,ax = plt.subplots(figsize=(18, len(ind_pos+ind_neg)/5))
f,ax = plt.subplots(figsize=(18, len(ind_pos+ind_neg)/10))
sns.heatmap(sub, fmt= '.1f',ax=ax, center = 0, yticklabels = True)
f.savefig(savedir+'featureplots/features_heat_{}_{}_{}_phases_1.pdf'.format(st, an, label))
f.savefig(savedir+'featureplots/features_heat_{}_{}_{}_phases_1.png'.format(st, an, label))
sub = df[half:]
f,ax = plt.subplots(figsize=(18, len(ind_pos+ind_neg)/5))
f,ax = plt.subplots(figsize=(18, len(ind_pos+ind_neg)/10))
sns.heatmap(sub, fmt= '.1f',ax=ax, center = 0, yticklabels = True)
f.savefig(savedir+'featureplots/features_heat_{}_{}_{}_phases_2.pdf'.format(st, an, label))
f.savefig(savedir+'featureplots/features_heat_{}_{}_{}_phases_2.png'.format(st, an, label))
......@@ -1074,11 +1074,21 @@ def plotter(subsets, subana, phases, labels):
if collections.Counter(mask[col])[True] < 1:
ls.append(col)
df.drop(ls, inplace = True)
half = math.floor(len(df.index)/2)
f,ax = plt.subplots(figsize=(18, len(ind_pos+ind_neg)/6))
sns.heatmap(df, fmt= '.1f',ax=ax, center = 0, yticklabels = True)
f.savefig(savedir+'featureplots/features_heat_{}_{}_{}_gender_phases.pdf'.format(st, an, label))
f.savefig(savedir+'featureplots/features_heat_{}_{}_{}_gender_phases.png'.format(st, an, label))
sub = df[0:half]
f,ax = plt.subplots(figsize=(18, len(ind_pos+ind_neg)/10))
sns.heatmap(sub, fmt= '.1f',ax=ax, center = 0, yticklabels = True)
f.savefig(savedir+'featureplots/features_heat_{}_{}_{}_gender_phases_1.pdf'.format(st, an, label))
f.savefig(savedir+'featureplots/features_heat_{}_{}_{}_gender_phases_1.png'.format(st, an, label))
sub =df[half:]
f,ax = plt.subplots(figsize=(18, len(ind_pos+ind_neg)/10))
sns.heatmap(sub, fmt= '.1f',ax=ax, center = 0, yticklabels = True)
f.savefig(savedir+'featureplots/features_heat_{}_{}_{}_gender_phases_2.pdf'.format(st, an, label))
f.savefig(savedir+'featureplots/features_heat_{}_{}_{}_gender_phases_2.png'.format(st, an, label))
return 1
......
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