Print Page   |   Sign In   |   Register
Question with typname('',type)
Moderator(s):
Thread Score:
Page 1 of 1
Thread Actions

12/23/2010 at 2:47:01 AM GMT
Posts: 45
Question with typname('',type)
I tried the following command in Scilab:

-->typename()
ans  =     1      2      4      5      6      7      8      9     10     11     13     14     15     16     17    128    129    130  

-->typename('',4)

-->typename()

ans  =  !--error 21 Invalid index.at line       3 of function %h_p called by :  typename()

In the manual, typename('',4) would suppress the data type given by its code type out of the tab of known data types. The problem for me is how to get it back?

In addition, would anyone tell more about why we would like to suppress some data type?  Thanks.


12/23/2010 at 5:22:53 PM GMT
Posts: 226
To get it back try this: typename('b',4)


List of names associated with type numbers

1, s
2, p
4, b
5, sp
6, spb
7, msp
8, i
9, h
10, c
11, m
13, mc
14, f
15, l
16, tl
17, ml
128, ptr
129, ip
130, fptr

To the question of why... it has to do with function overloading which is complicated. 


12/24/2010 at 1:46:04 AM GMT
Posts: 45
I tried
typename('b',4)

But no use. Still got the same message... :(


Community Search
Sign In


Forgot your password?

Register Now!

Scilab Tips


Privacy Policy © 2014 Equalis LLC Terms of Use