Strong, Weak, Intra
// This source code is subject to the terms of the Mozilla Public License 2.0 at https://mozilla.org/MPL/2.0/

//@version=5

indicator("Strong, Weak, Intra", overlay=true)

group_s     = 'Strong Levels'
group_w     = 'Weak Levels'
group_i     = 'Intra Day Levels'   


group_levels_s = 'Strong Levels:'
s18 = input.float(title='Strong', defval=0.0, inline='s12', group=group_levels_s)
s17 = input.float(title='Strong', defval=0.0, inline='s12', group=group_levels_s)
s16 = input.float(title='Strong', defval=0.0, inline='s12', group=group_levels_s)
s15 = input.float(title='Strong', defval=0.0, inline='s10', group=group_levels_s)
s14 = input.float(title='Strong', defval=0.0, inline='s10', group=group_levels_s)
s13 = input.float(title='Strong', defval=0.0, inline='s10', group=group_levels_s)
s12 = input.float(title='Strong', defval=0.0, inline='s8', group=group_levels_s)
s11 = input.float(title='Strong', defval=0.0, inline='s8', group=group_levels_s)
s10 = input.float(title='Strong', defval=0.0, inline='s8', group=group_levels_s)
s9 = input.float(title='Strong', defval=0.0, inline='s6', group=group_levels_s)
s8 = input.float(title='Strong', defval=0.0, inline='s6', group=group_levels_s)
s7 = input.float(title='Strong', defval=0.0, inline='s6', group=group_levels_s)
s6 = input.float(title='Strong', defval=0.0, inline='s4', group=group_levels_s)
s5 = input.float(title='Strong', defval=0.0, inline='s4', group=group_levels_s)
s4 = input.float(title='Strong', defval=0.0, inline='s4', group=group_levels_s)
s3 = input.float(title='Strong', defval=0.0, inline='s2', group=group_levels_s)
s2 = input.float(title='Strong', defval=0.0, inline='s2', group=group_levels_s)
s1 = input.float(title='Strong', defval=0.0, inline='s2', group=group_levels_s)


group_levels_w = 'Weak Levels:'
w18 = input.float(title='Weak', defval=0.0, inline='w9', group=group_levels_w)
w17 = input.float(title='Weak', defval=0.0, inline='w9', group=group_levels_w)
w16 = input.float(title='Weak', defval=0.0, inline='w9', group=group_levels_w)
w15 = input.float(title='Weak', defval=0.0, inline='w0', group=group_levels_w)
w14 = input.float(title='Weak', defval=0.0, inline='w0', group=group_levels_w)
w13 = input.float(title='Weak', defval=0.0, inline='w0', group=group_levels_w)
w12 = input.float(title='Weak', defval=0.0, inline='w1', group=group_levels_w)
w11 = input.float(title='Weak', defval=0.0, inline='w1', group=group_levels_w)
w10 = input.float(title='Weak', defval=0.0, inline='w1', group=group_levels_w)
w9 = input.float(title='Weak', defval=0.0, inline='w3', group=group_levels_w)
w8 = input.float(title='Weak', defval=0.0, inline='w3', group=group_levels_w)
w7 = input.float(title='Weak', defval=0.0, inline='w3', group=group_levels_w)
w6 = input.float(title='Weak', defval=0.0, inline='w5', group=group_levels_w)
w5 = input.float(title='Weak', defval=0.0, inline='w5', group=group_levels_w)
w4 = input.float(title='Weak', defval=0.0, inline='w5', group=group_levels_w)
w3 = input.float(title='Weak', defval=0.0, inline='w7', group=group_levels_w)
w2 = input.float(title='Weak', defval=0.0, inline='w7', group=group_levels_w)
w1 = input.float(title='Weak', defval=0.0, inline='w7', group=group_levels_w)

group_levels_i = 'Intra Day Levels:'
i8 = input.float(title='Intra', defval=0.0, inline='i8', group=group_levels_i)
i7 = input.float(title='Intra', defval=0.0, inline='i8', group=group_levels_i)
i6 = input.float(title='Intra', defval=0.0, inline='i6', group=group_levels_i)
i5 = input.float(title='Intra', defval=0.0, inline='i6', group=group_levels_i)
i4 = input.float(title='Intra', defval=0.0, inline='i4', group=group_levels_i)
i3 = input.float(title='Intra', defval=0.0, inline='i4', group=group_levels_i)
i2 = input.float(title='Intra', defval=0.0, inline='i2', group=group_levels_i)
i1 = input.float(title='Intra', defval=0.0, inline='i2', group=group_levels_i)


hline(s18, title='strong', color=color.white, linestyle=hline.style_solid, linewidth=2)
hline(s17, title='strong', color=color.white, linestyle=hline.style_solid, linewidth=2)
hline(s16, title='strong', color=color.white, linestyle=hline.style_solid, linewidth=2)
hline(s15, title='strong', color=color.white, linestyle=hline.style_solid, linewidth=2)
hline(s14, title='strong', color=color.white, linestyle=hline.style_solid, linewidth=2)
hline(s13, title='strong', color=color.white, linestyle=hline.style_solid, linewidth=2)
hline(s12, title='strong', color=color.white, linestyle=hline.style_solid, linewidth=2)
hline(s11, title='strong', color=color.white, linestyle=hline.style_solid, linewidth=2)
hline(s10, title='strong', color=color.white, linestyle=hline.style_solid, linewidth=2)
hline(s9,  title='strong', color=color.white, linestyle=hline.style_solid, linewidth=2)
hline(s8,  title='strong', color=color.white, linestyle=hline.style_solid, linewidth=2)
hline(s7,  title='strong', color=color.white, linestyle=hline.style_solid, linewidth=2)
hline(s6,  title='strong', color=color.white, linestyle=hline.style_solid, linewidth=2)
hline(s5,  title='strong', color=color.white, linestyle=hline.style_solid, linewidth=2)
hline(s4,  title='strong', color=color.white, linestyle=hline.style_solid, linewidth=2)
hline(s3,  title='strong', color=color.white, linestyle=hline.style_solid, linewidth=2)
hline(s2,  title='strong', color=color.white, linestyle=hline.style_solid, linewidth=2)
hline(s1,  title='strong', color=color.white, linestyle=hline.style_solid, linewidth=2)

hline(w18, title='weak', color=color.gray, linestyle=hline.style_dashed, linewidth=1)
hline(w17, title='weak', color=color.gray, linestyle=hline.style_dashed, linewidth=1)
hline(w16, title='weak', color=color.gray, linestyle=hline.style_dashed, linewidth=1)
hline(w15, title='weak', color=color.gray, linestyle=hline.style_dashed, linewidth=1)
hline(w14, title='weak', color=color.gray, linestyle=hline.style_dashed, linewidth=1)
hline(w13, title='weak', color=color.gray, linestyle=hline.style_dashed, linewidth=1)
hline(w12, title='weak', color=color.gray, linestyle=hline.style_dashed, linewidth=1)
hline(w11, title='weak', color=color.gray, linestyle=hline.style_dashed, linewidth=1)
hline(w10, title='weak', color=color.gray, linestyle=hline.style_dashed, linewidth=1)
hline(w9,  title='weak', color=color.gray, linestyle=hline.style_dashed, linewidth=1)
hline(w8,  title='weak', color=color.gray, linestyle=hline.style_dashed, linewidth=1)
hline(w7,  title='weak', color=color.gray, linestyle=hline.style_dashed, linewidth=1)
hline(w6,  title='weak', color=color.gray, linestyle=hline.style_dashed, linewidth=1)
hline(w5,  title='weak', color=color.gray, linestyle=hline.style_dashed, linewidth=1)
hline(w4,  title='weak', color=color.gray, linestyle=hline.style_dashed, linewidth=1)
hline(w3,  title='weak', color=color.gray, linestyle=hline.style_dashed, linewidth=1)
hline(w2,  title='weak', color=color.gray, linestyle=hline.style_dashed, linewidth=1)
hline(w1,  title='weak', color=color.gray, linestyle=hline.style_dashed, linewidth=1)


hline(i8, title='intra', color=color.gray, linestyle=hline.style_dotted, linewidth=1)
hline(i7, title='intra', color=color.gray, linestyle=hline.style_dotted, linewidth=1)
hline(i6, title='intra', color=color.gray, linestyle=hline.style_dotted, linewidth=1)
hline(i5, title='intra', color=color.gray, linestyle=hline.style_dotted, linewidth=1)
hline(i4, title='intra', color=color.gray, linestyle=hline.style_dotted, linewidth=1)
hline(i3, title='intra', color=color.gray, linestyle=hline.style_dotted, linewidth=1)
hline(i2, title='intra', color=color.gray, linestyle=hline.style_dotted, linewidth=1)
hline(i1, title='intra', color=color.gray, linestyle=hline.style_dotted, linewidth=1)
plot(close)