Scilab Home page | Wiki | Bug tracker | Forge | Mailing list archives | ATOMS | File exchange
Please login or create an account
Change language to: Français - Português - 日本語

Please note that the recommended version of Scilab is 5.5.2. This page might be outdated.
However, this page did not exist in the previous stable version.

Scilab help >> Output functions > printf


Emulator of C language printf function

Calling Sequence




a Scilab string. Specifies a character string combining literal characters with conversion specifications.


Specifies the data to be converted according to the format parameter.


The printf function converts, formats, and writes its value parameters, under control of the format parameter, to the standard output.

The format parameter is a character string that contains two types of objects:

Literal characters

which are copied to the output stream.

Conversion specifications

each of which causes zero or more items to be fetched from the value parameter list. see printf_conversion for details

If any values remain after the entire format has been processed, they are ignored.


printf('Result is:\nalpha=%f',0.535)

See Also

  • string — conversion to string
  • print — prints variables in a file
  • write — write in a formatted file
  • format — number printing and display format
  • disp — displays variables
  • file — file management
  • fprintf — Emulator of C language fprintf function
  • sprintf — Emulator of C language sprintf function
  • printf_conversion — printf, sprintf, fprintf conversion specifications


Add a comment:
Please login to comment this page.

<< print Output functions printf_conversion >>

Scilab Enterprises
Copyright (c) 2011-2015 (Scilab Enterprises)
Copyright (c) 1989-2012 (INRIA)
Copyright (c) 1989-2007 (ENPC)
with contributors
Last updated:
Thu May 12 11:44:27 CEST 2011