2016-03-25 16:47:20 -07:00
# Plot Image
2016-04-01 16:22:47 -07:00
The plot image function.
2016-03-25 16:47:20 -07:00
2016-11-01 10:42:42 -07:00
Display an [Image ](/reference/images/image ) on the @boardname @'s [LED screen ](/device/screen )
2016-03-25 16:47:20 -07:00
2017-09-07 13:42:08 -07:00
## JavaScript
2016-03-25 16:47:20 -07:00
2016-08-09 16:55:43 +01:00
```sig
2016-03-25 16:47:20 -07:00
export function plotImage(_this: micro_bit.Image, xOffset: number)
```
2017-09-07 13:42:08 -07:00
## Parameters
2016-03-25 16:47:20 -07:00
2017-03-16 07:57:41 -07:00
* x offset - [Number ](/types/number ); the horizontal starting point of an image; use 0 for the first frame of the image, 5 for the second frame of the image, 10 for the third frame and so on.
2016-03-25 16:47:20 -07:00
2017-09-07 13:42:08 -07:00
## Difference from `show image`
2016-03-25 16:47:20 -07:00
The `show image` function has a built in delay of 400ms after display of the image, whereas `plot image` has no built-in delay.
2017-09-07 13:42:08 -07:00
## Example
2016-03-25 16:47:20 -07:00
2016-08-09 16:55:43 +01:00
```blocks
2016-03-25 16:47:20 -07:00
let img = images.createImage(`
# . . . # # . . . #
. # . # . . # # # .
. . # . . . # # # .
. # . # . . # # # .
# . . . # # . . . #
`)
img.plotImage(0)
```
2017-09-07 13:42:08 -07:00
## See also
2016-03-25 16:47:20 -07:00
2016-04-15 15:02:26 -07:00
[create image ](/reference/images/create-image ), [show animation ](/reference/basic/show-animation ), [image ](/reference/images/image ), [show image ](/reference/images/show-image ), [scroll image ](/reference/images/scroll-image )
2016-03-25 16:47:20 -07:00