# How can I remove edges from my DiscretePlot?

By default, DiscretePlot displays "edges" along the sides and, prominently, align the top when ExtentSize -> Full is set. For example

DiscretePlot[{0.0273981, 0.0161957, 0.0164603, 0.0200524, 0.0235201,
0.0291751, 0.0203139, 0.00744914, 0.0206204, 0.0215697, 0.0841179,
0.0243641, 0.0200671, 0.0262562, 0.0268045, 0.0398572, 0.030682,
0.0279297, 0.0266079, 0.0303529, 0.0301269, 0.030297, 0.0111498,
0.0292085, 0.0334679, 0.0300855, 0.0264582, 0.0237181, 0.0287921,
0.0267715, 0., 0.0278168, 0.0267868, 0.0206096, 0.0223239,
0.0178952, 0.00802177, 0.020115, 0.0227009, 0.0238601}[[x]], {x, 1,
40}, PlotRange -> Full, ExtentSize -> Full, PlotStyle -> Gray]


produces

How can I eliminate these features so that the bars are colored and shaded evenly throughout.

-
For fun: does anyone recognize the plot? –  raxacoricofallapatorius May 22 '14 at 18:01
Try PlotRange -> Full, PlotStyle -> Lighter@Gray, ExtentSize -> Full, ExtentElementFunction -> "Rectangle" –  belisarius May 22 '14 at 18:08
@Öskå: I'm trying to remove all the edges. So no (a) line along the top, and (b) no lines between the bars. Ideally I'd like to have the option to have (b) but not (a). –  raxacoricofallapatorius May 22 '14 at 18:09
Oh, (b) but not (a).. –  Öskå May 22 '14 at 18:11

You can play with ExtentElementFunction and PlotStyle:

DiscretePlot[{0.0273981, 0.0161957, 0.0164603, 0.0200524, 0.0235201,
0.0291751, 0.0203139, 0.00744914, 0.0206204, 0.0215697, 0.0841179,
0.0243641, 0.0200671, 0.0262562, 0.0268045, 0.0398572, 0.030682,
0.0279297, 0.0266079, 0.0303529, 0.0301269, 0.030297, 0.0111498,
0.0292085, 0.0334679, 0.0300855, 0.0264582, 0.0237181, 0.0287921,
0.0267715, 0., 0.0278168, 0.0267868, 0.0206096, 0.0223239,
0.0178952, 0.00802177, 0.020115, 0.0227009, 0.0238601}[[x]], {x, 1,
40}, PlotRange -> Full, ExtentSize -> Full,
PlotStyle -> Directive[{EdgeForm[{Thin, Opacity@0}], LightGray, Opacity@.5}],
ExtentElementFunction -> "Rectangle"]


-
Excellent. Where did you learn that?! –  raxacoricofallapatorius May 22 '14 at 18:12
I pressed F1 on ExtentSize and found ExtentElementFunction.. :) Since "ArrowRectangle" existed I assumed that "Rectangle" should too. –  Öskå May 22 '14 at 18:13
@Öskå No need to assume ChartElementData["DiscretePlot"] –  belisarius May 22 '14 at 18:29
@belisarius Yes.., I saw it after by evaluating what is being said in the documentation. But "Rectangle" is not here.. –  Öskå May 22 '14 at 18:32
@Öskå Just evaluate it. The docs show an erroneous result. –  belisarius May 22 '14 at 18:34

You can use PlotStyleto control the styling of the "tops" while FillingStylecontrols the style of the "bar".

DiscretePlot[{0.0273981, 0.0161957, 0.0164603, 0.0200524, 0.0235201,
0.0291751, 0.0203139, 0.00744914, 0.0206204, 0.0215697, 0.0841179,
0.0243641, 0.0200671, 0.0262562, 0.0268045, 0.0398572, 0.030682,
0.0279297, 0.0266079, 0.0303529, 0.0301269, 0.030297, 0.0111498,
0.0292085, 0.0334679, 0.0300855, 0.0264582, 0.0237181, 0.0287921,
0.0267715, 0., 0.0278168, 0.0267868, 0.0206096, 0.0223239,
0.0178952, 0.00802177, 0.020115, 0.0227009, 0.0238601}[[x]], {x, 1,
40}, PlotRange -> Full, ExtentSize -> Full,
FillingStyle -> Opacity[0.5, Gray], PlotStyle -> Opacity[0], ImageSize -> 800]


-