Posts

csv - R code suddenly stopped working in tidy text -

i trying word analysis on data in r. imported 1 column of data text responses survey r using read.csv. named 1 of columns "text" . code working fine few days ago , giving me error. code entering: library(dplyr) library(tidytext) a1<-read.csv("/users/laura/documents/a1.csv") colnames(a1)= c("text") a1<-a1%>%unnest_tokens(word, text) the error getting says this: error in check_input(x) : input must character vector of length or list of character vectors, each of has length of 1. my data didn't change, code i'm using didn't change. :( don't understand why happening , new r... there package need load maybe had loaded before , didn't realize it? here link data: https://www.dropbox.com/s/amg12jp9qx98slz/a1.csv?dl=0 thanks help i used data provided on dropbox , following code seems running me no problems. maybe try reading in not csv? library(dplyr) library(tidytext) library(readr) a1 ...

ORACLE query using NOT IN too many values -

i have oracle query below: select * wa_ga_tbl_activity a, wa_ga_tbl_users u a.userid_fk = u.userid , (a.groupid_fk = 'gr0001' or u.groupid_fk = 'gr0001') , a.userid_fk != 'us0007' , (a.activityid) not in(select activityid_fk wa_ga_tbl_accessactivity userid_fk = 'us0007' the first logic check in wa_ga_tbl_activity when userid != us0007 . , want user details in not in : not in(select activityid_fk wa_ga_tbl_accessactivity userid_fk = 'us0007' when userid_fk = us0007 i tried this: select * wa_ga_tbl_activity a, wa_ga_tbl_users u a.userid_fk = u.userid , (a.groupid_fk = 'gr0001' or u.groupid_fk = 'gr0001') , a.userid_fk != 'us0007' , (a.activityid) not in(select s.userid, s.dateadded, w.activityid_fk wa_ga_tbl_users s, wa_ga_tbl_accessactivity w s.userid = w.userid_fk , w.userid_fk = 'us0007') got error: ora-00913: many values sample data table wa_ga_tbl_activity activityid | activityname...

c++ - Intel icpc and C++14: How to constexpr std::complex? -

in calculations use imaginary unit , think compiler should able simplify these operations @ compile time reducing things like a + b --> std::complex(a,b) of course above simplified , expressions more complex (pun intended). in c++14 can use complex literals that, whereas in c++11 using constexpr std::complex variable. however, both of these methods fail intel c++ compiler icpc error messages comments in source. how can work around these glitches? #include <complex> auto test1(double a, double b) { // error #1909: complex integral types not supported using namespace std::complex_literals; auto z = + 1i*b; return z; } auto test2(double a, double b) { // error: calling default constructor "std::complex<double>" not produce constant value constexpr std::complex<double> i(0,1); auto z = + i*b; return z; } auto test3(double a, double b) { // can optimized others? std::complex<double> i(0,1); auto z = + i*b; retu...

jquery - Slide div out of screen and other div into screen at the same time -

Image
i'm building mobile web app (apk not link) , know how compile. i'd give real app feel (effects). i have far: is there way make whole div slide left while div slides right fill in place when click category? i'm looking simple code so, i'll take anything. thanks! based on comment here basic code started. $('.button').click(function() { if ($(this).hasclass('button-right')) { $('.block1').css('marginleft', '-100%') } else { // hasclass button-left $('.block1').css('marginleft', '0%') } }) html, body { height: 100vh; margin: 0; padding: 0; background-color: green; } div { display: flex; height: 100%; } .container { position: relative; display: flex; flex: 1; } .blocks { display: flex; justify-content: center; align-items: center; flex: 1; min-width: 100%; transition: 0.3s ease; } .block1 { margin-left: 0; ba...

asp.net - Adobe PDF not showing on IIS7 -

Image
i got code below working on local (using source code) fine. when published on iis7 pdf not showing anymore.. there problem iis or ?. . . spent many days on problem. dim strpath = server.mappath("~\reports\generatedreport.pdf") my_rpt.exporttodisk(exportformattype.portabledocformat, strpath) dim file = new system.io.fileinfo(strpath) dim process = new process() if file.exists process.startinfo.useshellexecute = true process.startinfo.filename = strpath process.start() else 'no report found end if as can notice in picture below see adobereader running not displaying on screen. when "not showing" assuming want pdf opened on client, not server. send file browser. process.start() start process server-side, if apppool allowed start process, open pdf on server. below how send file server client. string strpath = server.mappath("~/reports/generatedreport.pdf"); //read file disk , convert byte array byte[] bin = file.r...

How to install Python Modules -

i want install pyserial python, don't know how. have tried stuff pip, doesn't recognise install command. how install it? first have install pip follow link .then can use pip install pyserial or can download pyserial gituhub , run python setup.py install

Google Chrome Extension Using With UDP -

i want develope basic extension. extension should communicate on udp. extension messaging. want create client. because create server in java. client can sent message server , server can message client. i @ chrome developer page. these documents not date. create basic client this: // values var address = null; var connect = null; var disconnect = null; // udp-object var echoclient = null; // ------------------------------------------------------------------------------------------------------------------- window.addeventlistener("load", function() { // input: address.val address = document.getelementbyid("address"); // button: connect.val connect = document.getelementbyid("connect"); // button: disconnect.val disconnect = document.getelementbyid("disconnect"); // button: connect.func connect.onclick = function(ev) { if(address.value != ""){ echoclient = newechoclient(address.value); ...