Posts

r - Vertical boxplot using chart.Boxplot -

i'm not able horizontal=false in chart.boxplot() produce vertical plot: require(performanceanalytics) z <- runif(1:100) chart.boxplot(z) chart.boxplot(z, horizontal=false) the 2 plots same. this performanceanalytics version 1.1.0 , r version 3.0.0. it small bug. should contact maintainer. should replace line ( in 2 places in code) boxplot(r[, column.order], horizontal = true,.. by boxplot(r[, column.order], horizontal = horizontal,...

node.js - Express JS and SocketIO Using -

sorry guys, here ask how using express js , socket io. new kind of tech. the 1st question is, necessary install express every project? mean, when want create new project,i create new folder, should run new command prompt, point directory , install express? if so, tell me offline please? because cant connect internet. the 2nd question is, if use express js, shall place client file such html / javascript(front end) in same directory server file? how can run example express project external source, such github? 3rd question is, have seen lot tutorial express js + socketio. 2 things framework,right? how can use them in project / folder? really appreciate , big if guys help, thank :) question 01: answer: don't have install express on each of project in order use it. can run command , install globally , can have offline. npm install -g express the above command install express globally, can use offline well. question 02: answer: recommendation of placing st...

html - Grow floated elements to fit inside -

i use full width of ul-element floated li-elements. somehow possible using %-values padding of li-elements? can't use fixed width lis, since content not same lenght. this html code: <ul> <li>january</li> <li>february</li> <li>march</li> <li>april</li> <li>may</li> <li>june</li> <li>...</li> </ul> and here comes css: ul { overflow: auto; list-style: none; margin: 0; padding: 0; width: 600px; background-color: blue; } li { float: left; padding-left: 3%; padding-right: 3%; background-color: #dd0000; border-left: 1px solid #ffffff; } li:hover { background-color: #ff0000; } find example @ jsfiddle: http://jsfiddle.net/6uy4y/ red li-elements should end, blue ul ends, when changing width of ul. thanks pointing me right direction! it looks start of tabular data. i'd use <table> . if ...

Importing Alexa data into Amazon RedShift -

i have taken daily dump file , unzipped , placed onto s3. when try , copy statement in postgresql receiving following error missing newline: unexpected character 0x14 found @ location 4 query: copy temp 's3://bucket/top-1m.csv' credentials 'blah blah blah'; do have add kinda character each line? raw data: 1,facebook.com 2,google.com 3,youtube.com 4,yahoo.com 5,amazon.com 6,baidu.com 7,wikipedia.org 8,live.com the redshift copy command uses pipe '|' default delimiter character. if files delimited character (comma in case), need add delimiter keyword copy command. copy temp 's3://bucket/top-1m.csv' credentials 'blah blah blah' delimiter ','; or comma separated files: copy temp 's3://bucket/top-1m.csv' credentials 'blah blah blah' csv;

FileWriter using netbeans not working -

here code print current time in file using netbeans not working. private void jbutton2actionperformed(java.awt.event.actionevent evt) { // todo add handling code here: // l1.settext(randomint+"cleaned files"); l1.settext("all viruses cleaned"); string timestamp = new simpledateformat("yyyymmdd_hhmmss").format(calendar.getinstance().gettime()); filewriter filewriter = null; try { string content = "hello! java-buddy :)"; filewriter f1=new filewriter("filename.txt"); f1.write(timestamp); f1.close(); } catch (ioexception ex) { system.out.println(ex.getmessage()); // logger.getlogger(writestringtofile.class.getname()).log(level.severe, null, ex); } }

3-Level Nested Array in PHP & MYSQL -

i trying create nested array, in order produce nested list within webpage. so far have managed following: array ( [2012] => array ( [show 1] => array ( [0] => class 1 ) [show 2] => array ( [0] => class 1 ) ) [2009] => array ( [show 1] => array ( [0] => class 1 ) ) [2008] => array ( [show 1] => array ( [0] => class 1 ) ) ) however actual results have more 1 class per show, should like: [2012] => array ( [show 1] => array ( [0] => class 1 [1] => class 2 [2] => class 3 ) etc etc etc. i've managed far, haven't clue how continue, in order more 1 class per show. my code follows: $handlerresults = $db->query(...

php - What is the right choice of XML encoding for Latin extended -

ok, need creat db interaction latin extended caracters such as: ŠšĐđČčĆ掞 etc.. now 1 way set encoding utf (which result db data caracters converted ššš (using latin1_swedish_ci colation).. this works fine while fetching data, unless need limit length of th field, problem when split occures in middle of Å¡, result caracter ?? instead of Ć.. so simple question, encoding use in html, , colation use inside db retain original caracters. thank you ` <!doctype html> <head><meta charset="utf-8"> </head> <body> <?php $dbx = new mysqli('localhost','root','pass','dbtester') or die ('error connection'); $query = $dbx->prepare ("select id, cont dbtester"); $query->execute(); $query->bind_result($id, $cont); while($query->fetch()): echo $id; echo $cont; endwhile; ?> </body> </html>` change storage...