Skip to content

Instantly share code, notes, and snippets.

<?php
//so the csv inputs correctly
ini_set("auto_detect_line_endings", "1");
/**
* Statistics Controller
*
*/
class StatisticsController extends AppController {
rake aborted!
bad URI(is not URI?):
/usr/local/lib/ruby/1.9.1/uri/common.rb:156:in `split'
/usr/local/lib/ruby/1.9.1/uri/common.rb:174:in `parse'
/usr/local/lib/ruby/1.9.1/uri/common.rb:628:in `parse'
/tmp/build_26digga9wajh3/config/initializers/redis.rb:1:in `<top (required)>'
/tmp/build_26digga9wajh3/vendor/bundle/ruby/1.9.1/gems/activesupport-3.2.8/lib/active_support/dependencies.rb:245:in `load'
/tmp/build_26digga9wajh3/vendor/bundle/ruby/1.9.1/gems/activesupport-3.2.8/lib/active_support/dependencies.rb:245:in `block in load'
/tmp/build_26digga9wajh3/vendor/bundle/ruby/1.9.1/gems/activesupport-3.2.8/lib/active_support/dependencies.rb:236:in `load_dependency'
/tmp/build_26digga9wajh3/vendor/bundle/ruby/1.9.1/gems/activesupport-3.2.8/lib/active_support/dependencies.rb:245:in `load'
void RunCmdPipe(commandT* cmd1, commandT* cmd2)
{
pid_t child;
int status = -1;
int pipe_status = -1;
int pid = 0;
fprintf (stdout,"executing %s () %s \n", cmd1->name, cmd2->argv[0]);
if ((child = fork()) > 0) // the shell parent process
{
void RunCmdPipeRecurse(commandTLinked* cmd){
int fd[2];
pipe(fd);
int grandchild_status = -1;
if(cmd->next != NULL){
pid_t grandchild;
grandchild = fork();
if(grandchild == 0) // grandchild process
RUN EXTRA CREDIT TEST CASES
test26: FAILED
Input:
alias showdir='echo ls'
showdir
exit
-- HOW IT SHOULD BE ------------------------------------------------------------ YOUR PROGRAM --------------------------------------------------------------
ls <
------------------------------------------------------------------------------------------------------------------------------------------------------------
test27: FAILED
CREATE TABLE user
(
email varchar(100) NOT NULL,
password varchar(50) NOT NULL,
PRIMARY KEY (email)
);
CREATE TABLE stocks
(
symbol varchar(10) NOT NULL,
/***************************************************************************
* Title: Kernel Memory Allocator
* -------------------------------------------------------------------------
* Purpose: Kernel memory allocator based on the resource map algorithm
* Author: Stefan Birrer
* Version: $Revision: 1.2 $
* Last Modification: $Date: 2009/10/31 21:28:52 $
* File: $RCSfile: kma_rm.c,v $
* Copyright: 2004 Northwestern University
***************************************************************************/
#!/usr/bin/perl -w
# use Getopt::Long;
require "header.pl";
$symbol = "APPL";#param("stock");
print `time_series_symbol_project.pl ORCL 8 AWAIT 300 ARIMA 2 1 2 | tail -20 2>&1`;
print `env`;
require "footer.pl";
elsif ($type eq "plot") {
print header(-type => 'image/png', -expires => '-1h' );
if (!defined($symbol)) {
# $symbol = 'AAPL'; # default
}
open(GNUPLOT,"| gnuplot") or die "Cannot run gnuplot";
print GNUPLOT "set term png\n"; # we want it to produce a PNG
print GNUPLOT "set output\n"; # output the PNG to stdout
get_covar_all.pl: ($count, $mean_f1,$std_f1, $mean_f2, $std_f2) = ExecStockSQL("ROW",$sql);
get_covar_all.pl: ($covar{$s1}{$s2}) = ExecStockSQL("ROW",$sql);
get_covar.pl: ($count, $mean_f1,$std_f1, $mean_f2, $std_f2) = ExecStockSQL("ROW",$sql);
get_covar.pl: ($covar{$s1}{$s2}) = ExecStockSQL("ROW",$sql);
get_data_for_predict.pl:my $data = ExecStockSQL("TEXT",$sql);
get_data_for_strat.pl:my $data = ExecStockSQL("TEXT",$sql);
get_data.pl:my $data = ExecStockSQL("TEXT",$sql);
get_info_beta.pl: $beta = ExecStockSQL("ROW",$sql2);
get_info_cvb.pl: ($n,$mean,$std,$min,$max) = ExecStockSQL("ROW",$sql);
get_info_cvb.pl: #$beta = ExecStockSQL("ROW",$sql2);