f



Can PHP array can hold 200-300 values for graphs

Hi,
I have to make graph from php array of around 300 values. I am using
PHPlots for making them.
And i have to use the values of array around 4-5 scripts.
So is it advisable to make that array a global variable or converting
data to a XML file and loading the values on need.
Regards
0
2/16/2008 12:16:22 PM
comp.lang.php 32646 articles. 0 followers. Post Follow

5 Replies
632 Views

Similar Articles

[PageSpeed] 32

An array can hold many thousands of elements. It would only be limited
by the available memory (PHP's memory_limit setting, your OS process
resource limits, physical RAM...).

On Feb 16, 7:16 am, "rahismail...@gmail.com" <rahismail...@gmail.com>
wrote:
> Hi,
> I have to make graph from php array of around 300 values. I am using
> PHPlots for making them.
> And i have to use the values of array around 4-5 scripts.
> So is it advisable to make that array a global variable or converting
> data to a XML file and loading the values on need.
> Regards

0
petersprc (357)
2/17/2008 1:28:26 AM
On 16 Feb, 12:16, "rahismail...@gmail.com" <rahismail...@gmail.com>
wrote:
> Hi,
> I have to make graph from php array of around 300 values. I am using
> PHPlots for making them.
> And i have to use the values of array around 4-5 scripts.
> So is it advisable to make that array a global variable or converting
> data to a XML file and loading the values on need.
> Regards

I was going to say that arrays would be ideal in this kind of scale
but if you're in the region of 4 digits plus, you should think about a
different way to handle the data. But then I saw you're thinking about
using XML instead. XML is not a way to solve scaling/performance
problems at this level.

C.
0
2/18/2008 9:51:54 AM
On Feb 18, 2:51 pm, "C. (http://symcbean.blogspot.com/)"
<colin.mckin...@gmail.com> wrote:
> On 16 Feb, 12:16, "rahismail...@gmail.com" <rahismail...@gmail.com>
> wrote:
>
> > Hi,
> > I have to make graph from php array of around 300 values. I am using
> > PHPlots for making them.
> > And i have to use the values of array around 4-5 scripts.
> > So is it advisable to make that array a global variable or converting
> > data to a XML file and loading the values on need.
> > Regards
>
> I was going to say that arrays would be ideal in this kind of scale
> but if you're in the region of 4 digits plus, you should think about a
> different way to handle the data. But then I saw you're thinking about
> using XML instead. XML is not a way to solve scaling/performance
> problems at this level.
>
> C.

I m not in region of 4 digits.
I m needed only of 3 digits but it is a 2D array.
Anyways as i needed it across many scripts so i have used it as a Xml
file.
Thanx for your reply
Regards
Rahi
0
2/18/2008 10:26:03 AM
rahismailbox@gmail.com wrote:
> On Feb 18, 2:51 pm, "C. (http://symcbean.blogspot.com/)"
> <colin.mckin...@gmail.com> wrote:
>> On 16 Feb, 12:16, "rahismail...@gmail.com" <rahismail...@gmail.com>
>> wrote:
>>
>>> Hi,
>>> I have to make graph from php array of around 300 values. I am using
>>> PHPlots for making them.
>>> And i have to use the values of array around 4-5 scripts.
>>> So is it advisable to make that array a global variable or converting
>>> data to a XML file and loading the values on need.
>>> Regards
>> I was going to say that arrays would be ideal in this kind of scale
>> but if you're in the region of 4 digits plus, you should think about a
>> different way to handle the data. But then I saw you're thinking about
>> using XML instead. XML is not a way to solve scaling/performance
>> problems at this level.
>>
>> C.
> 
> I m not in region of 4 digits.
> I m needed only of 3 digits but it is a 2D array.
> Anyways as i needed it across many scripts so i have used it as a Xml
> file.
> Thanx for your reply
> Regards
> Rahi
> 

Which is a very inefficient way to do it...

-- 
==================
Remove the "x" from my email address
Jerry Stuckle
JDS Computer Training Corp.
jstucklex@attglobal.net
==================

0
jstucklex (14659)
2/18/2008 1:31:52 PM
Greetings, rahismailbox@gmail.com.
In reply to Your message dated Saturday, February 16, 2008, 15:16:22,

> I have to make graph from php array of around 300 values. I am using
> PHPlots for making them.
> And i have to use the values of array around 4-5 scripts.
> So is it advisable to make that array a global variable or converting
> data to a XML file and loading the values on need.

I have a script dealing with about 2 millions of 2d points in one array.
So.. I guess it can hold a 1/10 part of that for You.


-- 
Sincerely Yours, AnrDaemon <anrdaemon@freemail.ru>

0
anrdaemon (327)
2/19/2008 5:22:56 PM
Reply: