Displaying 20 results from an estimated 2000 matches similar to: "Read data with different column lengths"
2011 Oct 01
1
error using ddply to generate means
Dear list,
I encounter an error when I try to use ddply to generate means as follows:
fun3<-structure(list(sector = structure(list(gics_sector_name = c("Financials",
"Financials", "Materials", "Materials")), .Names = "gics_sector_name",
row.names = structure(c("UBSN VX Equity",
"LLOY LN Equity", "AI FP Equity",
2006 Nov 22
1
RBloomberg Multi-ticker problem
Hi,
I am trying to download data from Bloomberg through R. If I try to
download intraday data for multiple tickers and only one field, I get
the error, written below in red. How do I get rid of this error?
> dat<-blpGetData(conn, c("NOK1V FH Equity","AUA AV Equity"),
"LAST_PRICE",
2011 Feb 23
3
Using string to call/manipulate an object
I am using getSymbols function from quantmod package to get price data from
internet.
Currently I have:
my.ticker <- "IBM"
getSymbols(my.ticker,src="google")
This creates an xts object named my.ticker which contains historical price
data for IBM.
How can I call and manipulating this xts object using my original string
my.ticker?
I want to do:
colnames(my.ticker) <-
2012 Oct 29
2
find the Best-ticker
i need to find the best ticker from the group of some tickers.?
i also need to know on what basis we calculate the best ticker?
i have some idea about the if the risk rate low, or the market price
high we can say the ticker is best.
but i dont know is it true.
Anyone can help me .
Thank you
--
View this message in context:
2009 Jun 25
1
apply on xts
Hi,
I do not understand why after I called apply on a function that returns an
xts (getIdvAdjSeries) it returns a matrix whose columns are just numeric
value of time series in xts instead of a list of xts objects.
Basically, I called the following:
apply(matrix(tickers,ncol=1),1,FUN=getDivAdjSeries)
getDivAdjSeries <- function(ticker) {
seriesName <-
2013 Nov 06
1
Multiple String word replacements: Performance Issue
Dear experts,
I?ve been on this for weeks now, and couldn?t find a solution..Sorry for the long description. I figured I post many details, so you get the problem entirely, although it?s not hard to grasp.
**Situation:**
Data frame consisting of 4 million entries (total size: 250 MB). Two columns: `ID` and `TEXT`. Text strings are each up to 200 characters.
**Task:**
Preprocessing the text
2011 Jan 19
1
Problem in using bdh function for Govt tickers
Hi, all
I wanted to fetch data from Bloomberg for govt bonds, and analyse it
further.
I am having trouble in getting data as when I use field=PX_LAST, it is
giving the prices but when I use field=CPN, or ISSUE_DT, it is not giving
the results and just bouncing back <NA> for that.
This is the piece of code:
> library(rJava)
Warning message:
package 'rJava' was built
2011 Apr 13
1
Assign with Paste Problem
Dear R Helpers,
I am trying to change the name of an object using the assign function.
When I use paste on the new object but not the old, everything is fine:
The new object is a direct copy of the old object. When I use a paste for
both the new and the old object, however, the new object is simply the
character representation of the old object name, not the old object
itself.
The example
2008 Sep 05
1
casting help please
I have a data.frame which I believe is melted already and am having
trouble casting it to 'wide' format.
It looks something like
> (x <- data.frame(ticker=c(rep("A",5),rep("B",6)), date=c(1:5, 1:6),
value=c(NA,100*exp(rnorm(10,0,.1)))))
> cast(x, date ~ ticker) # this does what I want with toy data
But when I use my real data frame
>
2010 Aug 03
4
mixing strings and numeric doubles in an array
I have an array called "stocks" which contains numeric dates, ticker
symbols,prices, etc.
> stocks[1:3,]
DATE TICKER PERMNO EXCHCD TSYMBOL TRDSTAT SHROUT PRC
RET
1 19950131 EWST 10001 3 EWST A
2224 -7.75000 -0.031250
2 19950228 EWST 10001 3 EWST A
2224 7.54688 -0.026210
3 19950331 EWST
2007 Jan 10
0
Column names in Zoo object
Hi,
I am downloading Bloomberg data from R. This data will be stored in a
zoo object by default. The command is
dat<-blpGetData(con,c("NOK1V FH Equity","AUA AV
Equity"),"PX_OPEN",start=as.chron(as.Date("12/1/2006",
"%m/%d/%Y")),end=as.chron(as.Date("12/28/2006", "%m/%d/%Y")))
Here I am downloading the data for two
2011 Dec 07
1
scatterplotting stock returns using quantmod and pairs()
I want to get data for a set of ticker symbols and compute the daily return of the adjusted close using quantmod, and then scatterplot returns using pairs().
The following gets data for the list of tickers:
tickers <- c("SHY","TLT","SPY","IWM","GLD","IEV","ILF","EWJ","EPP","SAF","ASA")
2011 Oct 07
2
Data frame aggregation
Hello,
Could anybody help me with this question?
Example data frame
NAME TICKER SHARES PERFORMANCE
John ABC 100 0.05
John ABC 1000 1.5
Alice EFG 20 0.3
Paul HIJ 50 1.0
Paul JKL 60 2.0
Paul MNO 12 3.0
I would like to aggregate this dataframe by
2012 Jul 07
1
Getting objects from quantmod ticker list
Hi all,
I would need to put datas downloaded with quantmod into a matrix or a data
frame.
Suppose to start from here:
*require(quantmod)
ticker.list <- c('AAA', 'ALTSALES', 'AMBNS', 'AMBSL', 'BAA', 'EMRATIO',
'FEDFUNDS', 'GASPRICE', 'GS1', 'GS10', 'GS20', 'LNS14100000', 'MORTG',
2011 Sep 01
4
[PATCH] xen,credit1: Add variable timeslice
Add a xen command-line parameter, sched_credit_tslice_ms,
to set the timeslice of the credit1 scheduler.
Signed-off-by: George Dunlap <george.dunlap@eu.citrix.com>
diff -r 4a4882df5649 -r 782284c5b1bc xen/common/sched_credit.c
--- a/xen/common/sched_credit.c Wed Aug 31 15:23:49 2011 +0100
+++ b/xen/common/sched_credit.c Thu Sep 01 16:29:50 2011 +0100
@@ -41,15 +41,9 @@
*/
#define
2004 Aug 09
1
error when calling debugger()
Hi,
I am getting an error message when I am trying to run the debugger() on
the last.dump. The debugger() stops after I make a selection. Could
someone please suggest what it might mean? The R log is included below.
This is R-1.8.1 on RH 7.3.
Thanks, Vadim
> load("last.dump.rda")
> debugger(last.dump)
Message: Error in split(x, f) : Group length is 0 but data length > 0
2011 Mar 23
1
using R variables in RMySQL query
I have the following function
myGetstockdataMySQL <- function(startdate, enddate, ticker) {
con <- dbConnect(MySQL(), user="blahblah", password="blahblah",
dbname="blahblah",
host="localhost")
rs <- dbGetQuery(con, "SELECT price.close FROM price INNER JOIN stocks ON
stocks.stock_id=price.stock_ID
WHERE (price.date_holding BETWEEN
2011 May 14
1
Changing Attribute With Paste
Dear R Helpers,
I am trying to adjust the attribute of an R object pulled from quantmod.
Since I want to do this for many such objects, I was trying to make the
adjustment programmatic. Unfortunately, I am having a huge amount of
trouble using attr in combination with paste (and perhaps get, and perhaps
assign, none of which seem to help). When I hard-code the change it works
fine. Your help
2010 Jan 20
7
Data Manipulation
Dear All,
I would like to to group the Ticker by Industry and create file names from
the
Industry Factor and export to a txt file.
I have tried the folowing
ind=finvizAllexETF$Industry
ind is then "Aluminum" "Business Services" "Regional Airlines"
ind2=gsub(" " ,"",ind)
ind3
[1] "Aluminum"
2009 Jul 06
1
how to apply a self-written function to a data frame
Hello,
I have written a function in order to analyse gaze paths. It works with the test data but when I try to apply the function to a data frame that stores "the real data" in columns I receive the error message that the
" In if (pp > 1) { :
condition has length > 1 only the first element will be used
"
I interpret this error message as saying that only the first