# What is the meaning of "line x, y, steps:Z"

**URL:** <https://in-thread.sonic-pi.net/t/what-is-the-meaning-of-line-x-y-steps-z/5558>\
**Category:** General\
**Created:** [May 22, 2021, 6:40am UTC](https://in-thread.sonic-pi.net/t/what-is-the-meaning-of-line-x-y-steps-z/5558 "2021-05-22T06:40:29Z")\
**Posts on this page:** 7\
**Page:** 1

<div class="post-metadata">

**Author:** ![Aguscao](https://avatars.discourse-cdn.com/v4/letter/a/5f9b8f/32.png) [@Aguscao](https://in-thread.sonic-pi.net/u/Aguscao)\
**Post date:** [May 22, 2021, 6:40am UTC](https://in-thread.sonic-pi.net/t/what-is-the-meaning-of-line-x-y-steps-z/5558/1 "2021-05-22T06:40:29Z")

</div>

Hi, I am Agus and I am new to Sonic Pi.  
Is there anybody here who can tell me the meaning of

1. line x, y, steps: z
2. (line 0.25, 1, steps: 100).reflect
3. (line -0.85, 0.85, steps: 100).tick

Where can I get a documentation of this line command?

Thank you.

---

<div class="post-metadata">

**Author:** ![ethancrawford](https://avatars.discourse-cdn.com/v4/letter/e/a88e4f/32.png) [@ethancrawford](https://in-thread.sonic-pi.net/u/ethancrawford)\
**Post date:** [May 22, 2021, 8:07am UTC](https://in-thread.sonic-pi.net/t/what-is-the-meaning-of-line-x-y-steps-z/5558/2 "2021-05-22T08:07:47Z")

</div>

Hello @Aguscao 🙂 Welcome to in\_thread!

> Where can I get a documentation of this line command?

These and all of the other built in functions are described in a language reference (titled ‘Lang’) in the app itself, in the Help panel. You can find this in several ways:

- through the top menu bar under View \> Show Help
- through the keyboard shortcut, Meta-I (Meta being Alt on Windows or Linux, Cmd on Mac)
- toggling the button in Sonic Pi’s button toolbar below the main menu.  
(Furthermore, if you are typing/navigating around the text in the editor and the cursor is on one of the Sonic Pi function names, (or synths, fx etc) you can hit Control-I and it will show help about that particular keyword directly).

So, you could move your cursor over the `line` command and hit Control-I, and the documentation for it will be shown. Have a read of that - and if you still have further questions, I’m sure someone would be able to help explain it 🙂

---

<div class="post-metadata">

**Author:** ![Aguscao](https://avatars.discourse-cdn.com/v4/letter/a/5f9b8f/32.png) [@Aguscao](https://in-thread.sonic-pi.net/u/Aguscao)\
**Post date:** [May 22, 2021, 8:32am UTC](https://in-thread.sonic-pi.net/t/what-is-the-meaning-of-line-x-y-steps-z/5558/3 "2021-05-22T08:32:49Z")

</div>

Oh, OK, I’ve found it, thank you.  
I am sure I have read this documentation several times, but never found this one.

Thanks again

---

<div class="post-metadata">

**Author:** ![nlb](https://dub1.discourse-cdn.com/flex017/user_avatar/in-thread.sonic-pi.net/nlb/32/997_2.png) [@nlb](https://in-thread.sonic-pi.net/u/nlb)\
**Post date:** [May 22, 2021, 11:27am UTC](https://in-thread.sonic-pi.net/t/what-is-the-meaning-of-line-x-y-steps-z/5558/4 "2021-05-22T11:27:22Z")

</div>

hi

```ruby
live_loop :differenceBetweenRangeAndLine do
  
  
  withRange = (range 0, 10, step: 1, inclusive: true).tick
  puts withRange
  # step : the value added each tick
  
  withLine = (line 0, 10, steps: 3, inclusive: true).tick("line")
  # steps describes the number of step to reach the end value
  puts withLine
  sleep 1
  
  
end

```

---

<div class="post-metadata">

**Author:** ![nlb](https://dub1.discourse-cdn.com/flex017/user_avatar/in-thread.sonic-pi.net/nlb/32/997_2.png) [@nlb](https://in-thread.sonic-pi.net/u/nlb)\
**Post date:** [May 22, 2021, 11:59am UTC](https://in-thread.sonic-pi.net/t/what-is-the-meaning-of-line-x-y-steps-z/5558/5 "2021-05-22T11:59:46Z")

</div>

> [@Aguscao](#):
>
> - (line 0.25, 1, steps: 100).reflect

no entry for reflect in the langage section ?.

---

<div class="post-metadata">

**Author:** ![nlb](https://dub1.discourse-cdn.com/flex017/user_avatar/in-thread.sonic-pi.net/nlb/32/997_2.png) [@nlb](https://in-thread.sonic-pi.net/u/nlb)\
**Post date:** [May 22, 2021, 1:45pm UTC](https://in-thread.sonic-pi.net/t/what-is-the-meaning-of-line-x-y-steps-z/5558/6 "2021-05-22T13:45:06Z")

</div>

an example to use reflect

```ruby
live_loop :up_down_amp do
  use_synth :piano
  r3 = (line 0, 1, steps: 20, inclusive: true).reflect
  foo = r3.length-1
  with_fx :echo, mix: 0.15 do
    play (scale :c4, :ahirbhairav, num_octaves: 2).reflect.tick("n"), amp: r3[0..foo].tick, sustain: 0.2
    sleep 0.1
  end  
end

```

---

<div class="post-metadata">

**Author:** ![Aguscao](https://avatars.discourse-cdn.com/v4/letter/a/5f9b8f/32.png) [@Aguscao](https://in-thread.sonic-pi.net/u/Aguscao)\
**Post date:** [May 22, 2021, 2:27pm UTC](https://in-thread.sonic-pi.net/t/what-is-the-meaning-of-line-x-y-steps-z/5558/7 "2021-05-22T14:27:07Z")

</div>

Thanks everyone, I have actually found the information I need in the help section of the program. Maybe I missed them somehow when I read it before, but now I have found it.

Thanks a lot.
