막대 차트에 0% 표시안녕,
백분율로 막대 차트를 작성하고 0%도 표시해야 합니다(스니플릿 그룹2에서).
Names Default To Here( 1 );
dt = New Table("Test");
dt << new column ("C", numeric, Continuous);
dt << new column ("D", numeric, Continuous);
dt << new column ("E", numeric, Continuous);
:C << set values([1,2,3]);
:D << set values([1,2,3]);
:E << set values([1,0,0.5]);
dt << new column ("Percent", numeric, Continuous, Format( "Percent", 15, 3 ), Formula(:E/:D));
dt << Graph Builder(
Size( 534, 454 ),
Show Control Panel( 0 ),
Variables( Y( :Percent ), Group X( :C ) ),
Elements( Bar( Y, Legend( 4 ), Label( "Label by Value" ) ) ),
SendToReport(
Dispatch(
{},
"Percent",
ScaleBox,
{Min( -0.113265306122449 ), Max( 1.08673469387755 ), Inc( 0.2 ),
Minor Ticks( 0 )}
)
)
);어떤 도움을 주셔서 감사합니다!
Re: 막대 차트에 0% 표시고마워요 잘 작동해요!Re: 막대 차트에 0% 표시또 다른 가능한 접근 방식은 다음 링크에서 찾을 수 있습니다.
https://community.jmp.com/t5/Discussions/force-all-histogram-levels-on-bar-graph-even-if-count-0/mp/195336#M41641
퍼센트에 적용해야 하는데 아직 시도하지 않았습니다.
Re: 막대 차트에 0% 표시안녕 @TWE ,
JMP가 실제로 0 값에 대한 레이블을 표시하도록 강제하는 방법을 모르겠습니다. 약간의 해결 방법이지만 과거에 제가 한 일은 값에 작은 양을 추가하여 jmp가 0으로 반올림하고 반올림된 값을 표시하도록 하는 것입니다. 예를 들어, 예를 사용하여 :E[2] 값을 0이 아닌 0.000000000000001로 설정하면 그래프에 0% 레이블이 표시됩니다.
Names Default To Here( 1 );
dt = New Table("Test");
dt << new column ("C", numeric, Continuous);
dt << new column ("D", numeric, Continuous);
dt << new column ("E", numeric, Continuous);
:C << set values([1,2,3]);
:D << set values([1,2,3]);
:E << set values([1,0.000000000000001,0.5]);
dt << new column ("Percent", numeric, Continuous, Format( "Percent", 15, 3 ), Formula(:E/:D));
dt << Graph Builder(
Size( 534, 454 ),
Show Control Panel( 0 ),
Variables( Y( :Percent ), Group X( :C ) ),
Elements( Bar( Y, Legend( 4 ), Label( "Label by Value" ) ) ),
SendToReport(
Dispatch(
{},
"Percent",
ScaleBox,
{Min( -0.113265306122449 ), Max( 1.08673469387755 ), Inc( 0.2 ),
Minor Ticks( 0 )}
)
)
);