Re: [Scilab-users] command longer than 4096

2023-04-27 Thread Federico Miyara


Jean-Yves.

Thank you for checking and confirming.

I think it is a limitation that could be relatively easily solved. If 
multi-line commands are accepted, it should be possible to automatically split 
the command using continuation marks before really requesting the execution.

Federico Miyara


On 27/04/2023 05:28, Jean-Yves Baudais wrote:
Hello,

Le 26/04/2023 à 17:20, Federico Miyara a écrit :
As I said yesterday, the single-line command doesn't work when selected
and evaluated from the contextual menu that opens when right-clicking on
the selection.

Ok, what I wrote was not in the same context, sorry. I succeeded to
obtain the same error message :-). So, it's a GUI problem. No? If yes,
maybe Java is responsible for that and fixes some prompt limitation?
(4096... is half of the input/output buffer size in C, by default, see
stdio.h)

Jean-Yves
___
users mailing list - users@lists.scilab.org
Click here to unsubscribe: 

https://lists.scilab.org/mailman/listinfo/users
This email and any attachments are intended solely for the use of the 
individual or entity to whom it is addressed and may be confidential and/or 
privileged.

If you are not one of the named recipients or have received this email in error,

(i) you should not read, disclose, or copy it,

(ii) please notify sender of your receipt by reply email and delete this email 
and all attachments,

(iii) Dassault Systèmes does not accept or assume any liability or 
responsibility for any use of or reliance on this email.


Please be informed that your personal data are processed according to our data 
privacy policy as described on our website. Should you have any questions 
related to personal data protection, please contact 3DS Data Protection Officer 
https://www.3ds.com/privacy-policy/contact/







[Avast logo] 

El software de antivirus Avast ha analizado este correo electrónico en busca de 
virus.
www.avast.com



This email and any attachments are intended solely for the use of the 
individual or entity to whom it is addressed and may be confidential and/or 
privileged.

If you are not one of the named recipients or have received this email in error,

(i) you should not read, disclose, or copy it,

(ii) please notify sender of your receipt by reply email and delete this email 
and all attachments,

(iii) Dassault Systèmes does not accept or assume any liability or 
responsibility for any use of or reliance on this email.


Please be informed that your personal data are processed according to our data 
privacy policy as described on our website. Should you have any questions 
related to personal data protection, please contact 3DS Data Protection Officer 
https://www.3ds.com/privacy-policy/contact/

___
users mailing list - users@lists.scilab.org
Click here to unsubscribe: 
https://lists.scilab.org/mailman/listinfo/users


Re: [Scilab-users] command longer than 4096

2023-04-27 Thread Jean-Yves Baudais

Hello,

Le 26/04/2023 à 17:20, Federico Miyara a écrit :

As I said yesterday, the single-line command doesn't work when selected
and evaluated from the contextual menu that opens when right-clicking on
the selection.


Ok, what I wrote was not in the same context, sorry. I succeeded to
obtain the same error message :-). So, it's a GUI problem. No? If yes,
maybe Java is responsible for that and fixes some prompt limitation?
(4096... is half of the input/output buffer size in C, by default, see
stdio.h)

Jean-Yves
___
users mailing list - users@lists.scilab.org
Click here to unsubscribe: 
https://lists.scilab.org/mailman/listinfo/users
This email and any attachments are intended solely for the use of the 
individual or entity to whom it is addressed and may be confidential and/or 
privileged.

If you are not one of the named recipients or have received this email in error,

(i) you should not read, disclose, or copy it,

(ii) please notify sender of your receipt by reply email and delete this email 
and all attachments,

(iii) Dassault Systèmes does not accept or assume any liability or 
responsibility for any use of or reliance on this email.


Please be informed that your personal data are processed according to our data 
privacy policy as described on our website. Should you have any questions 
related to personal data protection, please contact 3DS Data Protection Officer 
https://www.3ds.com/privacy-policy/contact/



Re: [Scilab-users] command longer than 4096

2023-04-26 Thread Federico Miyara


As I said yesterday, the single-line command doesn't work when selected and 
evaluated from the contextual menu that opens when right-clicking on the 
selection.

The error message,
Command is too long (more than 4096 characters long): could not send it to 
Scilab
is misleading, since the problem isn't the length of the command but the fact that it is 
in a single line of more than 4096 characters long. When the command is split into 
several lines by using the continuation mark "..", it works fine, of which I 
wasn't aware in my original post and I apologize for that.

When executing using either the "play" icon, F5 or exec(), both single-line and 
multiple-line versions of the command work as expected, of which I wasn't aware either.

Regards,

Federico Miyara


On 26/04/2023 05:17, Jean-Yves Baudais wrote:
Hello,

I wrote the vector "a" on the file "test.sce" and did

--> exec test.sce;
--> size(a)
ans  =

  1.   371.


Tested on Scilab 6.1.1. So it seems to work fine. I also tested a row
vector of 1 "1" and it works also! (I have many sce files like that,
because I use to add "a=[" at the beginning of ascii-matrix data files,
and "];" at the end. Maybe it's not the most efficient way to read and
store data, but it's the simplest for me :-)

Jean-Yves
___
users mailing list - users@lists.scilab.org
Click here to unsubscribe: 

https://lists.scilab.org/mailman/listinfo/users
This email and any attachments are intended solely for the use of the 
individual or entity to whom it is addressed and may be confidential and/or 
privileged.

If you are not one of the named recipients or have received this email in error,

(i) you should not read, disclose, or copy it,

(ii) please notify sender of your receipt by reply email and delete this email 
and all attachments,

(iii) Dassault Systèmes does not accept or assume any liability or 
responsibility for any use of or reliance on this email.


Please be informed that your personal data are processed according to our data 
privacy policy as described on our website. Should you have any questions 
related to personal data protection, please contact 3DS Data Protection Officer 
https://www.3ds.com/privacy-policy/contact/





[https://ipmcdn.avast.com/images/icons/icon-envelope-tick-round-orange-animated-no-repeat-v1.gif]
  Libre de virus. 
www.avast.com

This email and any attachments are intended solely for the use of the 
individual or entity to whom it is addressed and may be confidential and/or 
privileged.

If you are not one of the named recipients or have received this email in error,

(i) you should not read, disclose, or copy it,

(ii) please notify sender of your receipt by reply email and delete this email 
and all attachments,

(iii) Dassault Systèmes does not accept or assume any liability or 
responsibility for any use of or reliance on this email.


Please be informed that your personal data are processed according to our data 
privacy policy as described on our website. Should you have any questions 
related to personal data protection, please contact 3DS Data Protection Officer 
https://www.3ds.com/privacy-policy/contact/

___
users mailing list - users@lists.scilab.org
Click here to unsubscribe: 
https://lists.scilab.org/mailman/listinfo/users


Re: [Scilab-users] command longer than 4096

2023-04-26 Thread Jean-Yves Baudais

Hello,

I wrote the vector "a" on the file "test.sce" and did

--> exec test.sce;
--> size(a)
ans  =

   1.   371.


Tested on Scilab 6.1.1. So it seems to work fine. I also tested a row
vector of 1 "1" and it works also! (I have many sce files like that,
because I use to add "a=[" at the beginning of ascii-matrix data files,
and "];" at the end. Maybe it's not the most efficient way to read and
store data, but it's the simplest for me :-)

Jean-Yves
___
users mailing list - users@lists.scilab.org
Click here to unsubscribe: 
https://lists.scilab.org/mailman/listinfo/users
This email and any attachments are intended solely for the use of the 
individual or entity to whom it is addressed and may be confidential and/or 
privileged.

If you are not one of the named recipients or have received this email in error,

(i) you should not read, disclose, or copy it,

(ii) please notify sender of your receipt by reply email and delete this email 
and all attachments,

(iii) Dassault Systèmes does not accept or assume any liability or 
responsibility for any use of or reliance on this email.


Please be informed that your personal data are processed according to our data 
privacy policy as described on our website. Should you have any questions 
related to personal data protection, please contact 3DS Data Protection Officer 
https://www.3ds.com/privacy-policy/contact/



Re: [Scilab-users] command longer than 4096

2023-04-25 Thread Federico Miyara


Vincent,

A question to be sure we understood the underlying problem.
How did you get this error message?
-  Using SciNotes (F5 shorcut for example)?
-  Using exec function?
-  Using copy/paste?

When testing the code I usually select a portion of code from SciNotes and use the 
contextual menu "Evaluate selection with echo".

However, I notice now that with F5 I don't experience the same problem...!

But I also notice that in other cases of commands longer than 4096 the problem 
doesn't show. When I use .. to continue on the next line, there is no problem. 
When the same data is included in a single very long line the problem arises.

I'm including at the end two examples. In the first one the data are ordered 
with frequent ..'s, in the second one I removed all the continuation marks with 
the consequence that it will not be accepted.

The expected behavior would be that there were no difference between the 
different ways of executing a command.

As final note, among the answers I received when I posted my quest, one 
included the proposal of a function which allows to read massive data as in my 
usage case from a block comment at the end of the file. This would be 
interesting also in order to alleviate the code.

Regards,

Federico Miyara
From: users 
<mailto:users-boun...@lists.scilab.org> On 
Behalf Of Federico Miyara
Sent: Thursday, November 17, 2022 10:21 PM
To: users@lists.scilab.org<mailto:users@lists.scilab.org>
Subject: Re: [Scilab-users] command longer than 4096




EXTERNAL EMAIL :  The sender of this email is external to 3DS. Be wary of the content 
and do not open unexpected attachments or links. If you consider this email as spam, 
you can click 
here<https://spam-report.3ds.com/?link=%3ca%20href=%22https://www.mailcontrol.com/sr/QZYlT7N8RGDGX2PQPOmvUqKJsUvVq31ZRDFtiiGhHpJZ_bGk0noliIY1G-osMefMsui7cG11ww75pl0FDW8fzw==%22%3ehere%3c/a%3e>
 (no login or additional action will be requested).




Christopher,

Yes, you understand correctly my case.

There is a reason that justifies my request: I often use my scripts as examples 
within a didactic context. They are exhaustively commented, for instance. I 
consider it preferable to have all the needed data in the same script since I 
cannot be sure that potential future users who find my script will also find 
the associated file with the data (sometimes one downloads a file for future 
use without checking whether we are downloading all the associated files).

Then they should also change the script according to the particular directory 
tree where they choose to place the data, which is an unnecessary distraction 
from the very point of the example.

I agree that it wouldn't be convenient nor practical to work in this way with 
very large data sets, but some 1000 data is not unusual.

Regards,

Federico Miyara
On 17/11/2022 05:16, Dang Ngoc Chan, Christophe wrote:

Hello Federico,



De : users 
<mailto:users-boun...@lists.scilab.org> De la 
part de Federico

Miyara Envoyé : jeudi 17 novembre 2022 03:36



I have to create a vector from a plain text containing about 700 decimal 
numbers, each one with several digits.

[...]

Is there a simple way to do this other than [...] saving the data as a

text file



To be sure I understand well :

in your Scilab script, you have something like



foo = [3.14, 1.414 ; 1.732 ...



with the 700 numbers written inside your script?



Of course your request is legitimate but IMHO, this is really not the best 
practice.

I warmly recommend to have the 700 numbers in a separate file.



Regards



--

Christophe Dang Ngoc Chan

Mechanical calculation engineer





a = [0.2146008   0.3126420   0.3616361   0.2922267   0.5664249   0.4826472   
0.3321719   0.5935095 ..
0.5015342   0.4368588   0.2693125   0.6325745   0.4051954   0.9184708   
0.0437334   0.4818509 ..
0.2639556   0.4148104   0.2806498   0.1280058   0.7783129   0.2119030   
0.1121355   0.6856896 ..
0.1531217   0.6970851   0.8415518   0.4062025   0.4094825   0.8784126   
0.1138360   0.1998338 ..
0.5618661   0.5896177   0.6853980   0.8906225   0.5042213   0.3493615   
0.3873779   0.9222899 ..
0.9488184   0.3435337   0.3760119   0.7340941   0.2615761   0.4993494   
0.2638578   0.5253563 ..
0.5376230   0.1199926   0.2256303   0.6274093   0.7608433   0.0485566   
0.6723950   0.2017173 ..
0.3911574   0.8300317   0.5878720   0.4829179   0.2232865   0.8400886   
0.1205996   0.2855364 ..
0.8607515   0.8494102   0.5257061   0.9931210   0.6488563   0.9923191   
0.0500420   0.7485507 ..
0.4104059   0.6084526   0.8544211   0.0642647   0.8279083   0.9262344   
0.5667211   0.5711639 ..
0.8160110   0.0568928   0.5595937   0.1249340   0.7279222   0.2677766   
0.5465335   0.9885408 ..
0.7395657   0.0037173   0.5900573   0.3096467   0.2552206   0.6251879   
0.1157417   0.6117004 ..
0.6783956   0.3320095   0.0258710   0.5174468   0.3916873   0.2413538   
0.5064435   0.4236102 ..
0.2893728   0.0887932  

Re: [Scilab-users] command longer than 4096

2023-04-25 Thread COUVERT Vincent
Dear Frederico,

A question to be sure we understood the underlying problem.
How did you get this error message?

-  Using SciNotes (F5 shorcut for example)?

-  Using exec function?

-  Using copy/paste?

Thanks.



From: users  On Behalf Of Federico Miyara
Sent: Thursday, November 17, 2022 10:21 PM
To: users@lists.scilab.org
Subject: Re: [Scilab-users] command longer than 4096



EXTERNAL EMAIL :  The sender of this email is external to 3DS. Be wary of the 
content and do not open unexpected attachments or links. If you consider this 
email as spam, you can click 
here<https://spam-report.3ds.com/?link=%3ca%20href=%22https://www.mailcontrol.com/sr/QZYlT7N8RGDGX2PQPOmvUqKJsUvVq31ZRDFtiiGhHpJZ_bGk0noliIY1G-osMefMsui7cG11ww75pl0FDW8fzw==%22%3ehere%3c/a%3e>
 (no login or additional action will be requested).




Christopher,

Yes, you understand correctly my case.

There is a reason that justifies my request: I often use my scripts as examples 
within a didactic context. They are exhaustively commented, for instance. I 
consider it preferable to have all the needed data in the same script since I 
cannot be sure that potential future users who find my script will also find 
the associated file with the data (sometimes one downloads a file for future 
use without checking whether we are downloading all the associated files).

Then they should also change the script according to the particular directory 
tree where they choose to place the data, which is an unnecessary distraction 
from the very point of the example.

I agree that it wouldn't be convenient nor practical to work in this way with 
very large data sets, but some 1000 data is not unusual.

Regards,

Federico Miyara
On 17/11/2022 05:16, Dang Ngoc Chan, Christophe wrote:

Hello Federico,



De : users 
<mailto:users-boun...@lists.scilab.org> De la 
part de Federico

Miyara Envoyé : jeudi 17 novembre 2022 03:36



I have to create a vector from a plain text containing about 700 decimal 
numbers, each one with several digits.

[...]

Is there a simple way to do this other than [...] saving the data as a

text file



To be sure I understand well :

in your Scilab script, you have something like



foo = [3.14, 1.414 ; 1.732 ...



with the 700 numbers written inside your script?



Of course your request is legitimate but IMHO, this is really not the best 
practice.

I warmly recommend to have the 700 numbers in a separate file.



Regards



--

Christophe Dang Ngoc Chan

Mechanical calculation engineer



General

This e-mail may contain confidential and/or privileged information. If you are 
not the intended recipient (or have received this e-mail in error), please 
notify the sender immediately and destroy this e-mail. Any unauthorized 
copying, disclosure or distribution of the material in this e-mail is strictly 
forbidden.

___

users mailing list - users@lists.scilab.org<mailto:users@lists.scilab.org>

Click here to unsubscribe: 
<mailto:users-unsubscr...@lists.scilab.org><mailto:users-unsubscr...@lists.scilab.org>

http://lists.scilab.org/mailman/listinfo/users







[Avast logo]<https://www.avast.com/antivirus>


El software de antivirus Avast ha analizado este correo electrónico en busca de 
virus.
www.avast.com<https://www.avast.com/antivirus>




This email and any attachments are intended solely for the use of the 
individual or entity to whom it is addressed and may be confidential and/or 
privileged.

If you are not one of the named recipients or have received this email in error,

(i) you should not read, disclose, or copy it,

(ii) please notify sender of your receipt by reply email and delete this email 
and all attachments,

(iii) Dassault Systèmes does not accept or assume any liability or 
responsibility for any use of or reliance on this email.


Please be informed that your personal data are processed according to our data 
privacy policy as described on our website. Should you have any questions 
related to personal data protection, please contact 3DS Data Protection Officer 
https://www.3ds.com/privacy-policy/contact/

___
users mailing list - users@lists.scilab.org
Click here to unsubscribe: <mailto:users-unsubscr...@lists.scilab.org>
https://lists.scilab.org/mailman/listinfo/users


Re: [Scilab-users] command longer than 4096 => get_blockcomment()

2023-02-01 Thread Samuel Gougeon

Hello Federico,

Sorry if this answer breaks the thread (despite you have forwarded your initial 
message to me with its full header):

Le 21/12/2022 à 03:15, Federico Miyara a écrit :

Dear All,

I have to create a vector from a plain text containing about 700 decimal 
numbers, each one with several digits. The total character count incuding 
spaces is about 5700, so when I run this command I get the following error:

"Command is too long (more than 4096 characters long): could not send it to 
Scilab"

Is there a simple way to do this other than splitting the text into two parts, 
each one with less than 4096 digits and then concatenating the vectors, or 
saving the data as a text file and reading the file into a string variable and 
converting to numbers?

Thanks,

Federico Miyara

Federico 
Miyara
 Thu, 17 Nov 2022 13:22:08 
-0800

Christopher,

Yes, you understand correctly my case.



There is a reason that justifies my request: I often use my scripts as examples 
within a didactic context. They are exhaustively commented, for instance. I 
consider it preferable to have all the needed data in the same script since I 
cannot be sure that potential future users who find my script will also find 
the associated file with the data (sometimes one downloads a file for future 
use without checking whether we are downloading all the associated files).Then 
they should also change the script according to the particular directory tree 
where they choose to place the data, which is an unnecessary distraction from 
the very point of the example.I agree that it wouldn't be convenient nor 
practical to work in this way with very large data sets, but some 1000 data is 
not unusual.

Regards,

Federico Miyara


I fully understand and share your concern.

I have noticeably met a similar situation and requirement during last summer, to build 
some Scilab tests applying to some "passive extra content".
In the PHP language (that occupied me for ~9000 hours in another life), i 
remembered of some ob_start(..)  ob_end(..) instructions: In a PHP script, 
all multi-line contents lying between these two instructions are send to a 
buffer, instead of being executed.
Then for instance it is possible to get this content in a string array, with 
$myyarray = ob_get_contents().

For Scilab, a similar feature can be implemented by putting the "passive 
content" into some block-comment.
I have implemented a get_blockcomment() function to read some block-comment in 
the Scilab script being currently executed.
The supported syntaxes are:
r = get_blockcomment() : reads and returns the next block-comment following 
this call.
r = get_blockcomment(n) : reads and returns the nth block-comment of the 
current file.
with r: column of text
Option doEval (boolean): evaluates the read content and returns the results e 
instead of it:
e = get_blockcomment( , %t)
e = get_blockcomment(n, %t)

If no block-comment can be read, [] is returned.
The unitary tests file of this function is attached.

This function was first implemented as an internal one.
But afterwards, like you, i've thought that it is a general usage function, and 
indeed i use it as well in other contexts.

I think it would be useful in Scilab.  Would this be right?
Maybe its name could be improved.

Best regards
Samuel


This email and any attachments are intended solely for the use of the 
individual or entity to whom it is addressed and may be confidential and/or 
privileged.

If you are not one of the named recipients or have received this email in error,

(i) you should not read, disclose, or copy it,

(ii) please notify sender of your receipt by reply email and delete this email 
and all attachments,

(iii) Dassault Systèmes does not accept or assume any liability or 
responsibility for any use of or reliance on this email.


Please be informed that your personal data are processed according to our data 
privacy policy as described on our website. Should you have any questions 
related to personal data protection, please contact 3DS Data Protection Officer 
https://www.3ds.com/privacy-policy/contact/

// =
// Scilab ( http://www.scilab.org/ ) - This file is part of Scilab
// Copyright (C) 2023 - Le Mans Université - Samuel GOUGEON
//
//  This file is distributed under the same license as the Scilab package.
// =
// <-- CLI SHELL MODE -->
// <-- NO CHECK REF -->
// <-- ENGLISH IMPOSED -->

// Unitary tests of get_blockcomments()
// 
/* First block comment:
 -4 -5 -6  1  9  9  6  2
  6 -1  7  1  2  7 -6 -2
*/
// Read the next block-comment following this call:
r = get_blockcomment();
ref = [ ""
"  3  8  2 -2  0 -7  2  9 

Re: [Scilab-users] command longer than 4096

2023-02-01 Thread Samuel Gougeon

Hello Federico,

Sorry if this answer breaks the thread (despite you have forwarded your initial 
message to me with its full header. Thanks):

Le 21/12/2022 à 03:15, Federico Miyara a écrit :

Dear All,

I have to create a vector from a plain text containing about 700 decimal 
numbers, each one with several digits. The total character count incuding 
spaces is about 5700, so when I run this command I get the following error:

"Command is too long (more than 4096 characters long): could not send it to 
Scilab"

Is there a simple way to do this other than splitting the text into two parts, 
each one with less than 4096 digits and then concatenating the vectors, or 
saving the data as a text file and reading the file into a string variable and 
converting to numbers?

Thanks,

Federico Miyara

Federico 
Miyara
 Thu, 17 Nov 2022 13:22:08 
-0800

Christopher,

Yes, you understand correctly my case.



There is a reason that justifies my request: I often use my scripts as examples 
within a didactic context. They are exhaustively commented, for instance. I 
consider it preferable to have all the needed data in the same script since I 
cannot be sure that potential future users who find my script will also find 
the associated file with the data (sometimes one downloads a file for future 
use without checking whether we are downloading all the associated files).Then 
they should also change the script according to the particular directory tree 
where they choose to place the data, which is an unnecessary distraction from 
the very point of the example.I agree that it wouldn't be convenient nor 
practical to work in this way with very large data sets, but some 1000 data is 
not unusual.

Regards,

Federico Miyara


I fully understand and share your concern.

I noticeably encountered a similar situation and requirement during last summer, to build 
some Scilab tests applied to some "passive extra content".
In the PHP language (that kept me busy for ~9000 hours in another life), i 
remembered some ob_start(..)  ob_end(..) instructions: In a PHP script, all 
multi-line contents lying between these two statements are send to a buffer, 
instead of being executed.
Then for instance it is possible to get this content in a string array, with 
$myarray = ob_get_contents().

For Scilab, a similar feature can be implemented by putting the "passive 
content" in a /* multiline block of comments */.
Thus, i have implemented a get_blockcomment() function to read some 
block-comment in the Scilab script being currently executed.

The supported syntaxes are:
r = get_blockcomment() : reads and returns the next block-comment following 
this call.
r = get_blockcomment(n) : reads and returns the nth block-comment of the 
current file.
with r: column of text
Option doEval (boolean): evaluates the content and returns the results e 
instead of it:
e = get_blockcomment( , %t)
e = get_blockcomment(n, %t)

If no block-comment can be read, [] is returned.
The unitary tests file of this function is attached.

This function was first implemented as an internal one.
But afterwards, like you, i've thought that it is a general usage function, and 
indeed i use it as well in other contexts.

I think it would be useful in Scilab.  Would this be right?
Maybe its name could be improved.

Best regards
Samuel


This email and any attachments are intended solely for the use of the 
individual or entity to whom it is addressed and may be confidential and/or 
privileged.

If you are not one of the named recipients or have received this email in error,

(i) you should not read, disclose, or copy it,

(ii) please notify sender of your receipt by reply email and delete this email 
and all attachments,

(iii) Dassault Systèmes does not accept or assume any liability or 
responsibility for any use of or reliance on this email.


Please be informed that your personal data are processed according to our data 
privacy policy as described on our website. Should you have any questions 
related to personal data protection, please contact 3DS Data Protection Officer 
https://www.3ds.com/privacy-policy/contact/

// =
// Scilab ( http://www.scilab.org/ ) - This file is part of Scilab
// Copyright (C) 2023 - Le Mans Université - Samuel GOUGEON
//
//  This file is distributed under the same license as the Scilab package.
// =
// <-- CLI SHELL MODE -->
// <-- NO CHECK REF -->
// <-- ENGLISH IMPOSED -->

// Unitary tests of get_blockcomments()
// 
/* First block comment:
 -4 -5 -6  1  9  9  6  2
  6 -1  7  1  2  7 -6 -2
*/
// Read the next block-comment following this call:
r = get_blockcomment();
ref = [ ""
"  

Re: [Scilab-users] command longer than 4096

2022-11-17 Thread Federico Miyara


Christopher,

Yes, you understand correctly my case.

There is a reason that justifies my request: I often use my scripts as 
examples within a didactic context. They are exhaustively commented, for 
instance. I consider it preferable to have all the needed data in the 
same script since I cannot be sure that potential future users who find 
my script will also find the associated file with the data (sometimes 
one downloads a file for future use without checking whether we are 
downloading all the associated files).


Then they should also change the script according to the particular 
directory tree where they choose to place the data, which is an 
unnecessary distraction from the very point of the example.


I agree that it wouldn't be convenient nor practical to work in this way 
with very large data sets, but some 1000 data is not unusual.


Regards,

Federico Miyara

On 17/11/2022 05:16, Dang Ngoc Chan, Christophe wrote:

Hello Federico,


De : users  De la part de Federico
Miyara Envoyé : jeudi 17 novembre 2022 03:36

I have to create a vector from a plain text containing about 700 decimal 
numbers, each one with several digits.
[...]
Is there a simple way to do this other than [...] saving the data as a
text file

To be sure I understand well :
in your Scilab script, you have something like

foo = [3.14, 1.414 ; 1.732 ...

with the 700 numbers written inside your script?

Of course your request is legitimate but IMHO, this is really not the best 
practice.
I warmly recommend to have the 700 numbers in a separate file.

Regards

--
Christophe Dang Ngoc Chan
Mechanical calculation engineer

General
This e-mail may contain confidential and/or privileged information. If you are 
not the intended recipient (or have received this e-mail in error), please 
notify the sender immediately and destroy this e-mail. Any unauthorized 
copying, disclosure or distribution of the material in this e-mail is strictly 
forbidden.
___
users mailing list - users@lists.scilab.org
Click here to unsubscribe: 
http://lists.scilab.org/mailman/listinfo/users






--
El software de antivirus Avast ha analizado este correo electrónico en busca de 
virus.
https://www.avast.com/antivirus
___
users mailing list - users@lists.scilab.org
Click here to unsubscribe: 
http://lists.scilab.org/mailman/listinfo/users


Re: [Scilab-users] command longer than 4096

2022-11-17 Thread Dang Ngoc Chan, Christophe
Hello Federico,

> De : users  De la part de Federico
> Miyara Envoyé : jeudi 17 novembre 2022 03:36
>
> I have to create a vector from a plain text containing about 700 decimal 
> numbers, each one with several digits.
> [...]
> Is there a simple way to do this other than [...] saving the data as a
> text file

To be sure I understand well :
in your Scilab script, you have something like

foo = [3.14, 1.414 ; 1.732 ...

with the 700 numbers written inside your script?

Of course your request is legitimate but IMHO, this is really not the best 
practice.
I warmly recommend to have the 700 numbers in a separate file.

Regards

--
Christophe Dang Ngoc Chan
Mechanical calculation engineer

General
This e-mail may contain confidential and/or privileged information. If you are 
not the intended recipient (or have received this e-mail in error), please 
notify the sender immediately and destroy this e-mail. Any unauthorized 
copying, disclosure or distribution of the material in this e-mail is strictly 
forbidden.
___
users mailing list - users@lists.scilab.org
Click here to unsubscribe: 
http://lists.scilab.org/mailman/listinfo/users