Skip to content

Commit

Permalink
Fix to append_columns so CytoFrameView sees new column
Browse files Browse the repository at this point in the history
  • Loading branch information
jacobpwagner committed Sep 10, 2020
1 parent 5afbec8 commit 94f2683
Showing 1 changed file with 3 additions and 6 deletions.
9 changes: 3 additions & 6 deletions inst/include/cytolib/CytoFrameView.hpp
Original file line number Diff line number Diff line change
Expand Up @@ -110,15 +110,12 @@ class CytoFrameView{
// Realize the view to the underlying cytoframe (if necessary) and then append extra columns.
// Realizing the view is necessary for unambiguous Pn indices for the added columns.
void append_columns(const vector<string> & new_colnames, const EVENT_DATA_VEC & new_cols){
CytoFramePtr ptr;
if(is_row_indexed() || is_col_indexed()){
// Realize to the original file
ptr = realize(get_cytoframe_ptr(), get_uri(), true);
// Realize to the original file and reset the view
ptr_ = realize(ptr_, get_uri(), true);
reset_view();
}else{
ptr = get_cytoframe_ptr();
}
ptr->append_columns(new_colnames, new_cols);
ptr_->append_columns(new_colnames, new_cols);
}

string get_marker(const string & channel)
Expand Down

0 comments on commit 94f2683

Please sign in to comment.