{"action":"created","issue":{"url":"https://api.github.com/repos/datastorm-open/visNetwork/issues/97","repository_url":"https://api.github.com/repos/datastorm-open/visNetwork","labels_url":"https://api.github.com/repos/datastorm-open/visNetwork/issues/97/labels{/name}","comments_url":"https://api.github.com/repos/datastorm-open/visNetwork/issues/97/comments","events_url":"https://api.github.com/repos/datastorm-open/visNetwork/issues/97/events","html_url":"https://github.com/datastorm-open/visNetwork/issues/97","id":178400753,"number":97,"title":"visOptions selectedBy bug?","user":{"login":"byandell","id":325732,"avatar_url":"https://avatars.githubusercontent.com/u/325732?v=3","gravatar_id":"","url":"https://api.github.com/users/byandell","html_url":"https://github.com/byandell","followers_url":"https://api.github.com/users/byandell/followers","following_url":"https://api.github.com/users/byandell/following{/other_user}","gists_url":"https://api.github.com/users/byandell/gists{/gist_id}","starred_url":"https://api.github.com/users/byandell/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/byandell/subscriptions","organizations_url":"https://api.github.com/users/byandell/orgs","repos_url":"https://api.github.com/users/byandell/repos","events_url":"https://api.github.com/users/byandell/events{/privacy}","received_events_url":"https://api.github.com/users/byandell/received_events","type":"User","site_admin":false},"labels":[],"state":"open","locked":false,"assignee":null,"assignees":[],"milestone":null,"comments":2,"created_at":"2016-09-21T16:39:17Z","updated_at":"2016-09-22T15:21:53Z","closed_at":null,"body":"Hi,\r\nI found two apparent bugs with visOptions. \r\n\r\n1. The help page refers to a data.frame column \"group\", which does not exist. Changing to \"level\" resolves this.\r\n2. If nodes is a tbl_df rather than a data.frame, there is an error message, and the \"Select by level\" menu on the viewer is messed up (one character per line of literal R).\r\n\r\nthanks,\r\nBrian\r\n---------\r\n**set up data**\r\n> nodes = data.frame(id = 1:6, level = c(1, 2, 3, 3, 4, 2))\r\n> edges = data.frame(from = c(1, 2, 2, 4, 6), to = c(2, 3, 4, 5, 4))\r\n\r\n**this does not work** \r\n> visNetwork(nodes, edges) %>% \r\n+     visOptions(selectedBy = \"group\")\r\nWarning message:\r\nIn visOptions(., selectedBy = \"group\") :\r\n  Can't find 'group' in node data.frame\r\n\r\n**this works**\r\n> visNetwork(nodes, edges) %>% \r\n+     visOptions(selectedBy = \"level\")\r\n\r\n**this does not work** \r\n> visNetwork(tbl_df(nodes), edges) %>% \r\n+     visOptions(selectedBy = \"level\")\r\nWarning message:\r\nUnknown column 'group' "},"comment":{"url":"https://api.github.com/repos/datastorm-open/visNetwork/issues/comments/248935782","html_url":"https://github.com/datastorm-open/visNetwork/issues/97#issuecomment-248935782","issue_url":"https://api.github.com/repos/datastorm-open/visNetwork/issues/97","id":248935782,"user":{"login":"byandell","id":325732,"avatar_url":"https://avatars.githubusercontent.com/u/325732?v=3","gravatar_id":"","url":"https://api.github.com/users/byandell","html_url":"https://github.com/byandell","followers_url":"https://api.github.com/users/byandell/followers","following_url":"https://api.github.com/users/byandell/following{/other_user}","gists_url":"https://api.github.com/users/byandell/gists{/gist_id}","starred_url":"https://api.github.com/users/byandell/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/byandell/subscriptions","organizations_url":"https://api.github.com/users/byandell/orgs","repos_url":"https://api.github.com/users/byandell/repos","events_url":"https://api.github.com/users/byandell/events{/privacy}","received_events_url":"https://api.github.com/users/byandell/received_events","type":"User","site_admin":false},"created_at":"2016-09-22T15:21:53Z","updated_at":"2016-09-22T15:21:53Z","body":"Great. Thanks!\nBrian\n\nFrom: \"B. Thieurmel\" <notifications@github.com<mailto:notifications@github.com>>\nReply-To: datastorm-open/visNetwork <reply@reply.github.com<mailto:reply@reply.github.com>>\nDate: Thursday, September 22, 2016 at 3:41 AM\nTo: datastorm-open/visNetwork <visNetwork@noreply.github.com<mailto:visNetwork@noreply.github.com>>\nCc: Brian Yandell <brian.yandell@wisc.edu<mailto:brian.yandell@wisc.edu>>, Author <author@noreply.github.com<mailto:author@noreply.github.com>>\nSubject: Re: [datastorm-open/visNetwork] visOptions selectedBy bug? (#97)\n\n\nHi,\n\nFirst one is not a bug. This help says : \"variable\" : Character. Column name of selection variable. so you can use any variable in node data.frame. In the example I put in the package, this is \"group\" column.\n\nFor the second point, I've just fix some bad interaction we can have using dplyr or data.table with some data.frame operations...\n\n-\nYou are receiving this because you authored the thread.\nReply to this email directly, view it on GitHub<https://github.com/datastorm-open/visNetwork/issues/97#issuecomment-248844100>, or mute the thread<https://github.com/notifications/unsubscribe-auth/AAT4ZCES_0myjiAStaEkOooG3CJesePFks5qsj8rgaJpZM4KDBhc>.\n"}}
{"actor":{"display_login":"byandell"}}