{"action":"created","issue":{"url":"https://api.github.com/repos/kbenoit/quanteda/issues/118","repository_url":"https://api.github.com/repos/kbenoit/quanteda","labels_url":"https://api.github.com/repos/kbenoit/quanteda/issues/118/labels{/name}","comments_url":"https://api.github.com/repos/kbenoit/quanteda/issues/118/comments","events_url":"https://api.github.com/repos/kbenoit/quanteda/issues/118/events","html_url":"https://github.com/kbenoit/quanteda/issues/118","id":143482205,"number":118,"title":"dfm constructor in batch mode","user":{"login":"tpaskhalis","id":2973437,"avatar_url":"https://avatars3.githubusercontent.com/u/2973437?v=4","gravatar_id":"","url":"https://api.github.com/users/tpaskhalis","html_url":"https://github.com/tpaskhalis","followers_url":"https://api.github.com/users/tpaskhalis/followers","following_url":"https://api.github.com/users/tpaskhalis/following{/other_user}","gists_url":"https://api.github.com/users/tpaskhalis/gists{/gist_id}","starred_url":"https://api.github.com/users/tpaskhalis/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/tpaskhalis/subscriptions","organizations_url":"https://api.github.com/users/tpaskhalis/orgs","repos_url":"https://api.github.com/users/tpaskhalis/repos","events_url":"https://api.github.com/users/tpaskhalis/events{/privacy}","received_events_url":"https://api.github.com/users/tpaskhalis/received_events","type":"User","site_admin":false},"labels":[],"state":"closed","locked":false,"assignee":null,"assignees":[],"milestone":null,"comments":6,"created_at":"2016-03-25T11:38:08Z","updated_at":"2017-07-19T14:13:01Z","closed_at":"2016-03-31T23:47:32Z","body":"R script with dfm constructor gives error when launched in batch mode with `Rscript` command. However, it executes fine when used with `R CMD BATCH`.\n\nFor example, the following simple script `test.R`:\n\n```\nlibrary(quanteda)\ndf <- dfm(ie2010Corpus)\n```\n\nfails with the following error when started with `Rscript test.R` from Ubuntu console:\n\n```\nAttaching package: ‘quanteda’\n\nThe following object is masked from ‘package:stats’:\n\n    df\n\nThe following object is masked from ‘package:base’:\n\n    sample\n\nCreating a dfm from a corpus ...\n   ... lowercasing\n   ... tokenizing\n   ... indexing documents: 14 documents\n   ... indexing features: 4,881 feature types\n   ... created a 14 x 4881 sparse dfm\n   ... complete. \nElapsed time: 0.113 seconds.\nError in UseMethod(\"features\") : \n  no applicable method for 'features' applied to an object of class \"dfmSparse\"\nCalls: dfm ... dfm.character -> dfm -> dfm.tokenizedTexts -> features\nExecution halted\n```\n\nbut runs perfectly fine when started as `R CMD BATCH test.R`:\n\n```\n> library(quanteda)\n\nAttaching package: ‘quanteda’\n\nThe following object is masked from ‘package:stats’:\n\n    df\n\nThe following object is masked from ‘package:base’:\n\n    sample\n\n>\n> df <- dfm(ie2010Corpus)\nCreating a dfm from a corpus ...\n   ... lowercasing\n   ... tokenizing\n   ... indexing documents: 14 documents\n   ... indexing features: 4,881 feature types\n   ... created a 14 x 4881 sparse dfm\n   ... complete.\nElapsed time: 0.217 seconds.\n>\n> proc.time()\n   user  system elapsed\n  2.101   0.419   2.107\n```\n"},"comment":{"url":"https://api.github.com/repos/kbenoit/quanteda/issues/comments/316400680","html_url":"https://github.com/kbenoit/quanteda/issues/118#issuecomment-316400680","issue_url":"https://api.github.com/repos/kbenoit/quanteda/issues/118","id":316400680,"user":{"login":"kbenoit","id":2182246,"avatar_url":"https://avatars2.githubusercontent.com/u/2182246?v=4","gravatar_id":"","url":"https://api.github.com/users/kbenoit","html_url":"https://github.com/kbenoit","followers_url":"https://api.github.com/users/kbenoit/followers","following_url":"https://api.github.com/users/kbenoit/following{/other_user}","gists_url":"https://api.github.com/users/kbenoit/gists{/gist_id}","starred_url":"https://api.github.com/users/kbenoit/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/kbenoit/subscriptions","organizations_url":"https://api.github.com/users/kbenoit/orgs","repos_url":"https://api.github.com/users/kbenoit/repos","events_url":"https://api.github.com/users/kbenoit/events{/privacy}","received_events_url":"https://api.github.com/users/kbenoit/received_events","type":"User","site_admin":false},"created_at":"2017-07-19T14:13:01Z","updated_at":"2017-07-19T14:13:01Z","body":"@Sangs181 Not sure what \"issue\" you are still getting - can you provide details as to the problem? Including `sessionInfo()` output, and code generating the problem so we can reproduce it?"}}
{"actor":{"display_login":"kbenoit"}}