code
stringlengths
3
6.57k
xp.max()
ax2.invert_xaxis()
ax3.yaxis_inverted()
ax2.invert_yaxis()
ax2.axis('off')
sca(ax3)
axes.remove(None)
colorbar(mappable=im, ax=axes, anchor=(0, 0)
colorbar(mappable=im, extend=cb_extend)
sca(ax3)
sci(im)
ImageCursor(ax3, im)
connect('button_press_event', cursor.onClick)
ax3.tick_params(axis='x', rotation=xtickrotation)
reorderMatrix(names, matrix, tree, axis=None)
ValueError('matrix should be a 2D matrix.')
TypeError('matrix should be a numpy array.')
np.shape(matrix)
np.shape(matrix)
ValueError('matrix should be a square matrix')
np.asarray(names)
np.isscalar(names)
TypeError('names should be list-like')
len(names)
TypeError('names is empty')
isinstance(tree, Phylo.BaseTree.Tree)
TypeError('tree should be a BioPython Tree')
len(names)
len(matrix)
ValueError('names should have entries for each matrix row/column')
tree.get_terminals()
len(names)
len(terminals)
ValueError('names should have entries for each tree terminal')
len(terminals)
len(matrix)
ValueError('matrix should have a row for each tree terminal')
np.where(names == name)
len(locs)
ValueError('inconsistent names and tree: %s not in names'%name)
len(locs)
ValueError('inconsistent names and tree: duplicate name %s in names'%name)
indices.append(locs[0])
np.arange(s)
np.isscalar(axis)
np.ix_(*I)
findSubgroups(tree, c, method='naive', **kwargs)
method.lower()
strip()
tree.get_terminals()
getLinkage(names, tree)
print('Failed to build linkage; fall back to naive criterion')
range(len(terminals)
tree.distance(curr_clade, next_clade)
subgroups.append([])
append(next_clade.name)
fcluster(Z, c, criterion=method, **kwargs)
np.unique(T)
range(len(labels)
enumerate(T)
append(names[i])
py.log.setconsumer("rtyper", py.log.STDOUT)
not_really_random()
random.random()
range(12000)
BaseTestRDict(BaseRtypingTest)
test_dict_creation(self)
createdict(i)
self.newdict()
self.interpret(createdict, [42])
test_dict_getitem_setitem(self)
func(i)
self.newdict()
self.interpret(func, [6])
test_dict_getitem_keyerror(self)
func(i)
self.newdict()
self.interpret(func, [6])
test_dict_del_simple(self)
func(i)
self.newdict()
len(d)
self.interpret(func, [6])
test_dict_clear(self)
func(i)
self.newdict()
d.clear()
len(d)
self.interpret(func, [7])
test_empty_strings(self)
func(i)
self.newdict()
self.interpret(func, [6])
func(i)
self.newdict()
len(d)
self.interpret(func, [6])
test_dict_bool(self)
func(i)
self.newdict()