Mercurial > repos > johnheap > vapper
comparison Tryp_V.py @ 3:4432e4183ebd draft
planemo upload for repository https://github.com/johnheap/VAPPER-Galaxy
| author | johnheap |
|---|---|
| date | Wed, 11 Jul 2018 08:58:14 -0400 |
| parents | 36cb22bd911d |
| children | e75a85590041 |
comparison
equal
deleted
inserted
replaced
| 2:82770f07a036 | 3:4432e4183ebd |
|---|---|
| 181 title, | 181 title, |
| 182 ha="left", va="top", wrap="True") | 182 ha="left", va="top", wrap="True") |
| 183 col = cg.ax_col_dendrogram.get_position() | 183 col = cg.ax_col_dendrogram.get_position() |
| 184 cg.ax_col_dendrogram.set_position([col.x0, col.y0*1.08, col.width, col.height*1.1]) | 184 cg.ax_col_dendrogram.set_position([col.x0, col.y0*1.08, col.width, col.height*1.1]) |
| 185 | 185 |
| 186 | 186 countryList = pd.unique(geo_df['Location']) |
| 187 colourList = pd.unique(geo_df['colour']) | |
| 187 legend_elements = [Patch(facecolor='orangered', label='COG Present'), | 188 legend_elements = [Patch(facecolor='orangered', label='COG Present'), |
| 188 Patch (facecolor='skyblue', label='COG Absent'), | 189 Patch(facecolor='skyblue', label='COG Absent')] |
| 189 Patch(facecolor='w', label=''), | 190 |
| 190 Patch (facecolor='b', label='Nigeria'), | 191 for i in range(0, len(colourList)): |
| 191 Patch(facecolor = 'g', label='Uganda'), | 192 print("country = %s, colour = %s" % (countryList[i], colourList[i])) |
| 192 Patch (facecolor='c', label='Gambia'), | 193 p = Patch(facecolor=str(colourList[i]), label=countryList[i]) |
| 193 Patch (facecolor='r', label='Ivory Coast'), | 194 legend_elements.append(p) |
| 194 Patch(facecolor='m', label='Brazil'), | 195 |
| 195 Patch(facecolor='k', label=name)] | |
| 196 #legend_test = [[Patch(facecolor='orangered'),Patch(facecolor='r')],["test","test2"]] | |
| 197 ax.legend(handles = legend_elements, bbox_to_anchor=(-0.3,1.2),loc = 'upper left') | 196 ax.legend(handles = legend_elements, bbox_to_anchor=(-0.3,1.2),loc = 'upper left') |
| 198 | 197 |
| 199 | 198 |
| 200 | 199 |
| 201 | 200 |
