Jumat, 24 Januari 2014

[smf_addin] Digest Number 2940

13 New Messages

Digest #2940
1a
gurufocus by lawleesh
1b
Re: gurufocus by lawleesh
2b
Re: smfGetOXOptionQuote() function question by "Randy Harmelink" rharmelink
4a
company name by port4olios
4b
Re: company name by "Randy Harmelink" rharmelink
4c
Re: company name by port4olios

Messages

Thu Jan 23, 2014 3:34 am (PST) . Posted by:

lawleesh

Hi Randy

Could you pls help me with the formula for Revenue in http://www.gurufocus.com/financials/SPRD http://www.gurufocus.com/financials/SPRD?

I kept getting Revenue per share.

thanks

LL

Thu Jan 23, 2014 8:01 am (PST) . Posted by:

lawleesh

I managed to find a an uploaded file in the Files segment that could do this. Thanks.

Thu Jan 23, 2014 8:59 am (PST) . Posted by:

atb1023


Randy
Can you tell me the URL that the smfGetOXOptionQuote() function utilizes?
Tommy

Thu Jan 23, 2014 11:49 am (PST) . Posted by:

"Randy Harmelink" rharmelink

It would be something like:

https://www.optionsxpress.com/OXNetTools/Chains/index.aspx?Range=0&lstMarket=0&ChainType=3&lstMonths=3/22/2014;1&Symbol=SPY

...with the date and ticker symbol changed as appropriate.

On Thu, Jan 23, 2014 at 9:59 AM, <tommybrown@cfl.rr.com> wrote:

>
> Can you tell me the URL that the smfGetOXOptionQuote() function utilizes?
>
>

Thu Jan 23, 2014 3:31 pm (PST) . Posted by:

jfpicasso

Hi All,

As this is my first post, I'd just like to thank everyone who has submitted to and moderates this forum and group for all of their work. It has been invaluable to me.

Now on to my question - I have limited experience with VBA (I can read and generally understand the gist of most of these modules, but could never edit them), but I was wondering if there was a way to modify the GetYahooHistory module to autosize the array output based on the size of the retrieved data.

For example, I could enter:

=RCHGetYahooHistory("AAPL";,2013,1,1,2014,1,1,,"A",0)

in cell A1, hit CTRL+SHIFT+ENTER, and the returned array would fill the 364 rows below A1 with the price history for the past year.

The value of doing this is that it would allow me to maintain a dynamic array of price history. The first date in the array would be the date I opened a position, and the second date in the array would be todays date, or some other date that updates in time dynamically. The result would be that everytime that later date updates, RCHGetYahooHistory would go out to the web, and pull in the new array of price history, AND resize its own array output based on the new size of days prices it drew down.

Thanks!

J

Thu Jan 23, 2014 3:37 pm (PST) . Posted by:

"Randy Harmelink" rharmelink

In EXCEL, a function can only return values to the range it has been given
access to (through the array-entering process). It can't modify the size of
that array. Nor can it do things like add cell formats to the cells. Just
values.

You can array-enter it over a larger range, and it will just fill down with
how much data it finds on Yahoo, blank-filling any unused cells in the
range.

On Thu, Jan 23, 2014 at 3:17 PM, <jfpicasso@yahoo.com> wrote:

> Now on to my question - I have limited experience with VBA (I can read and
> generally understand the gist of most of these modules, but could never
> edit them), but I was wondering if there was a way to modify the
> GetYahooHistory module to autosize the array output based on the size of
> the retrieved data.
>
> For example, I could enter:
>
> =RCHGetYahooHistory("AAPL";,2013,1,1,2014,1,1,,"A",0)
>
> in cell A1, hit CTRL+SHIFT+ENTER, and the returned array would fill the
> 364 rows below A1 with the price history for the past year.
>
> The value of doing this is that it would allow me to maintain a dynamic
> array of price history. The first date in the array would be the date I
> opened a position, and the second date in the array would be todays date,
> or some other date that updates in time dynamically. The result would be
> that everytime that later date updates, RCHGetYahooHistory would go out to
> the web, and pull in the new array of price history, AND resize its own
> array output based on the new size of days prices it drew down.
>

Thu Jan 23, 2014 3:43 pm (PST) . Posted by:

"Peter Urbani" purbani1

That can be done - but it is not exactly simple see;

http://www.ozgrid.com/forum/showthread.php?t=93405

AND

http://www.wilmott.com/messageview.cfm?catid=10&threadid=62734

On Fri, Jan 24, 2014 at 11:17 AM, <jfpicasso@yahoo.com> wrote:

>
>
> Hi All,
>
>
>
> As this is my first post, I'd just like to thank everyone who has
> submitted to and moderates this forum and group for all of their work. It
> has been invaluable to me.
>
>
>
> Now on to my question - I have limited experience with VBA (I can read and
> generally understand the gist of most of these modules, but could never
> edit them), but I was wondering if there was a way to modify the
> GetYahooHistory module to autosize the array output based on the size of
> the retrieved data.
>
>
>
> For example, I could enter:
>
>
>
> =RCHGetYahooHistory("AAPL";,2013,1,1,2014,1,1,,"A",0)
>
>
>
> in cell A1, hit CTRL+SHIFT+ENTER, and the returned array would fill the
> 364 rows below A1 with the price history for the past year.
>
>
>
> The value of doing this is that it would allow me to maintain a dynamic
> array of price history. The first date in the array would be the date I
> opened a position, and the second date in the array would be todays date,
> or some other date that updates in time dynamically. The result would be
> that everytime that later date updates, RCHGetYahooHistory would go out to
> the web, and pull in the new array of price history, AND resize its own
> array output based on the new size of days prices it drew down.
>
>
>
> Thanks!
>
>
>
> J
>
>
>

--

*Peter Urbani*

+64 6 378 0937

LinkedIn Profile <http://nz.linkedin.com/in/peterurbani>

Skype peterurbani

Thu Jan 23, 2014 3:47 pm (PST) . Posted by:

"Randy Harmelink" rharmelink

Those change the size of the array WHILE in VBA. But they still can only
return values to the range the formula was array-entered over.

On Thu, Jan 23, 2014 at 4:43 PM, Peter Urbani <peter.urbani@gmail.com>wrote:

>
> That can be done - but it is not exactly simple see;
>
> http://www.ozgrid.com/forum/showthread.php?t=93405
>
> AND
>
> http://www.wilmott.com/messageview.cfm?catid=10&threadid=62734
>
>

Thu Jan 23, 2014 4:19 pm (PST) . Posted by:

mikemcq802

I'll probably regret throwing what little expertise I have in here but, Randy, couldn't the problem be solved in a different way?

That is, what if you had something like smfUpdateDownloadTable create the history outside of an array and then define a constant name to the range of data you created (say, "smfHistory&quot;). Then, other parts of the book could just lookup based on this created name?

I know you can do stuff like that via Powershell so I'm guessing it could be done in vba too.

Frankly, I'm not sure what large benefit this provides over just having a large pre-defined array and just ignoring the ending blanks. Just thinking out loud about the problem asked.

Thu Jan 23, 2014 5:04 pm (PST) . Posted by:

"Randy Harmelink" rharmelink

I would just do what you suggest, and ignore the extra lines of blanks at
the end...

As long as enough history is returned, it can be extracted from or
manipulated any way that is desired.

On Thu, Jan 23, 2014 at 5:19 PM, <mikemcq802@yahoo.com> wrote:

>
> I'll probably regret throwing what little expertise I have in here but,
> Randy, couldn't the problem be solved in a different way?
>
> That is, what if you had something like smfUpdateDownloadTable create the
> history outside of an array and then define a constant name to the range of
> data you created (say, "smfHistory&quot;). Then, other parts of the book could
> just lookup based on this created name?
>
> I know you can do stuff like that via Powershell so I'm guessing it could
> be done in vba too.
>
> Frankly, I'm not sure what large benefit this provides over just having a
> large pre-defined array and just ignoring the ending blanks. Just thinking
> out loud about the problem asked.
>

Thu Jan 23, 2014 4:05 pm (PST) . Posted by:

port4olios


I receive Error from =RCHGetElementNumber("MMM";,13863). I would appreciate any guidance. Thanks

Thu Jan 23, 2014 4:12 pm (PST) . Posted by:

"Randy Harmelink" rharmelink

Exit and restart EXCEL, opening a new workbook. What do you get with:

=RCHGetElementNumber("MMM";,13863)
=RCHGetElementNumber("Version&quot;)
=smfGetAParms(13863)
=smfstrExtr(smfGetTagContent("http://finance.yahoo.com/q?s=MMM","title"),"Summary
for ","-")
=smfGetTagContent("http://finance.yahoo.com/q?s=MMM","title")

On Thu, Jan 23, 2014 at 5:04 PM, <port4olios@yahoo.com> wrote:

> I receive Error from =RCHGetElementNumber("MMM";,13863). I would
> appreciate any guidance. Thanks
>

Thu Jan 23, 2014 6:54 pm (PST) . Posted by:

port4olios

I thought I had the most recent version of smf installed. I had 12-29-2012. Updated to 10-17-2013 and got


3M Company Common Stock


Stock Market Functions add-in, Verson 2.1.2013.10.17 (C:\Program Files\SMF Add-In; ; 1)


blank


3M Company Common Stock


MMM: Summary for 3M Company Common Stock- Yahoo! Finance


Thanks

Tidak ada komentar:

Posting Komentar