Skip to content

Commit

Permalink
Merge pull request biolab#1855 from VesnaT/fix_transpose
Browse files Browse the repository at this point in the history
[FIX] Table.transpose: Keep metas array two dimensional when no attributes in domain
(cherry picked from commit e380ca2)
  • Loading branch information
lanzagar authored and astaric committed Jan 10, 2017
1 parent e8273a7 commit 7676934
Showing 1 changed file with 2 additions and 1 deletion.
3 changes: 2 additions & 1 deletion Orange/data/table.py
Original file line number Diff line number Diff line change
Expand Up @@ -1513,7 +1513,8 @@ def get_table_from_attributes_of_attributes(_vars, _dtype=float):
# metas
# - feature names and attributes of attributes to metas
self.metas, metas = np.empty((self.n_rows, 0), dtype=object), []
if meta_attr_name not in [m.name for m in table.domain.metas]:
if meta_attr_name not in [m.name for m in table.domain.metas] and \
table.domain.attributes:
self.metas = np.array([[a.name] for a in table.domain.attributes],
dtype=object)
metas.append(StringVariable(meta_attr_name))
Expand Down

0 comments on commit 7676934

Please sign in to comment.