Skip to content

Instantly share code, notes, and snippets.

@prateekjoshi565
Created December 29, 2019 06:11
Show Gist options
  • Save prateekjoshi565/6a545e73facb22fc8dc8d0c60cfb714c to your computer and use it in GitHub Desktop.
Save prateekjoshi565/6a545e73facb22fc8dc8d0c60cfb714c to your computer and use it in GitHub Desktop.
# create dataframe of removable edges
fb_df_ghost = fb_df.loc[omissible_links_index]
# add the target variable 'link'
fb_df_ghost['link'] = 1
data = data.append(fb_df_ghost[['node_1', 'node_2', 'link']], ignore_index=True)
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment