{"action":"created","issue":{"url":"https://api.github.com/repos/JuliaStats/DataFrames.jl/issues/1095","repository_url":"https://api.github.com/repos/JuliaStats/DataFrames.jl","labels_url":"https://api.github.com/repos/JuliaStats/DataFrames.jl/issues/1095/labels{/name}","comments_url":"https://api.github.com/repos/JuliaStats/DataFrames.jl/issues/1095/comments","events_url":"https://api.github.com/repos/JuliaStats/DataFrames.jl/issues/1095/events","html_url":"https://github.com/JuliaStats/DataFrames.jl/issues/1095","id":181508234,"number":1095,"title":"reference level of contrasts in ModelMatrix ","user":{"login":"dmbates","id":371258,"avatar_url":"https://avatars.githubusercontent.com/u/371258?v=3","gravatar_id":"","url":"https://api.github.com/users/dmbates","html_url":"https://github.com/dmbates","followers_url":"https://api.github.com/users/dmbates/followers","following_url":"https://api.github.com/users/dmbates/following{/other_user}","gists_url":"https://api.github.com/users/dmbates/gists{/gist_id}","starred_url":"https://api.github.com/users/dmbates/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/dmbates/subscriptions","organizations_url":"https://api.github.com/users/dmbates/orgs","repos_url":"https://api.github.com/users/dmbates/repos","events_url":"https://api.github.com/users/dmbates/events{/privacy}","received_events_url":"https://api.github.com/users/dmbates/received_events","type":"User","site_admin":false},"labels":[],"state":"open","locked":false,"assignee":null,"assignees":[],"milestone":null,"comments":6,"created_at":"2016-10-06T19:46:55Z","updated_at":"2016-10-07T14:16:24Z","closed_at":null,"body":"I noticed that tests began failing on the master version of the [`GLM package`](https://github.com/JuliaStats/GLM.jl) and eventually tracked the problem to the default contrasts for a `CategoricalVector` not using the same ordering as the levels.  See [this example](https://github.com/dmbates/JSM/blob/master/Contrasts.ipynb).\r\n\r\nIn the example my GLM package repository is dirty because I had made some changes and was running the package tests before committing the changes.  That was when I saw this problem. "},"comment":{"url":"https://api.github.com/repos/JuliaStats/DataFrames.jl/issues/comments/252263889","html_url":"https://github.com/JuliaStats/DataFrames.jl/issues/1095#issuecomment-252263889","issue_url":"https://api.github.com/repos/JuliaStats/DataFrames.jl/issues/1095","id":252263889,"user":{"login":"dmbates","id":371258,"avatar_url":"https://avatars.githubusercontent.com/u/371258?v=3","gravatar_id":"","url":"https://api.github.com/users/dmbates","html_url":"https://github.com/dmbates","followers_url":"https://api.github.com/users/dmbates/followers","following_url":"https://api.github.com/users/dmbates/following{/other_user}","gists_url":"https://api.github.com/users/dmbates/gists{/gist_id}","starred_url":"https://api.github.com/users/dmbates/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/dmbates/subscriptions","organizations_url":"https://api.github.com/users/dmbates/orgs","repos_url":"https://api.github.com/users/dmbates/repos","events_url":"https://api.github.com/users/dmbates/events{/privacy}","received_events_url":"https://api.github.com/users/dmbates/received_events","type":"User","site_admin":false},"created_at":"2016-10-07T14:16:24Z","updated_at":"2016-10-07T14:16:24Z","body":"@nalimilan You probably know that the behavior in R is not to reevaluate the levels when using `getindex` but to have a separate function `droplevels` which drops unused levels, if there are any.  It should be very fast to determine the levels represented using `IntSet(var.refs)` which could be used in a `droplevels` function."}}
{"actor":{"display_login":"dmbates"}}