Statalist


[Date Prev][Date Next][Thread Prev][Thread Next][Date index][Thread index]

Re: st: mata


From   "David M. Drukker" <[email protected]>
To   [email protected]
Subject   Re: st: mata
Date   Fri, 3 Aug 2007 11:08:27 -0500 (CDT)

Alexander Staus <[email protected]> obtained the error
message "no room to add more double literals" when putting values into a
Mata matrix.

For instance, Alexander is performing an operation like

X = (123456, 789101123 \
234567, 891011121 )

but with more elements.

The number of elements currently allowed for this type of operation is
100, which is very small.

In a future update, we will expand this limit so that it no longer binds.

In the meantime, as a work-around, Alexander can put his values into a Stata
dataset and then use -st_data()- to put the values into a Mata matrix.

Here is an example.

. input v1 v2

v1 v2
1. 123456 789101123
2. 234567 891011121
3. end

. . mata: --------------------------------- mata (type end to exit) --------------------
: x = st_data(., tokens("v1 v2"))

: x
1 2
+-------------------------+
1 | 123456 789101120 |
2 | 234567 891011136 |
+-------------------------+

: end
-------------------------------------------------------------------------------

--David
[email protected]

*
* For searches and help try:
* http://www.stata.com/support/faqs/res/findit.html
* http://www.stata.com/support/statalist/faq
* http://www.ats.ucla.edu/stat/stata/




© Copyright 1996–2024 StataCorp LLC   |   Terms of use   |   Privacy   |   Contact us   |   What's new   |   Site index