also use scale for histogram
Some checks failed
FarmMaps.Develop/FarmMapsLib/pipeline/head There was a failure building this commit
Some checks failed
FarmMaps.Develop/FarmMapsLib/pipeline/head There was a failure building this commit
This commit is contained in:
parent
127dc44917
commit
8e304fc6eb
@ -1,15 +1,15 @@
|
|||||||
<div class="row ps-3">
|
<div class="row ps-3">
|
||||||
<div class="col-8 nopadding"><span i18n>Average</span>:</div>
|
<div class="col-8 nopadding"><span i18n>Average</span>:</div>
|
||||||
<div class="col-4 pull-left nopadding">{{histogram.mean| number:'1.0-2'}}</div>
|
<div class="col-4 pull-left nopadding">{{ getScaledValue(histogram.mean| number:'1.0-2')}}</div>
|
||||||
<div class="col-8 nopadding"><span i18n>Standard deviation</span>:</div>
|
<div class="col-8 nopadding"><span i18n>Standard deviation</span>:</div>
|
||||||
<div class="col-4 pull-left nopadding">{{histogram.stddev| number:'1.0-2'}}</div>
|
<div class="col-4 pull-left nopadding">{{ getScaledValue(histogram.stddev| number:'1.0-2')}}</div>
|
||||||
<div class="col-8 nopadding"><span i18n>Min</span>:</div>
|
<div class="col-8 nopadding"><span i18n>Min</span>:</div>
|
||||||
<div class="col-4 pull-left nopadding">{{histogram.min| number:'1.0-2'}}</div>
|
<div class="col-4 pull-left nopadding">{{ getScaledValue(histogram.min| number:'1.0-2')}}</div>
|
||||||
<div class="col-8 nopadding" ><span i18n>Max</span>:</div>
|
<div class="col-8 nopadding" ><span i18n>Max</span>:</div>
|
||||||
<div class="col-4 pull-left nopadding">{{histogram.max| number:'1.0-2'}}</div>
|
<div class="col-4 pull-left nopadding">{{ getScaledValue(histogram.max| number:'1.0-2')}}</div>
|
||||||
|
|
||||||
<ng-container *ngIf="showConfidenceInterval()">
|
<ng-container *ngIf="showConfidenceInterval()">
|
||||||
<div class="col-8 nopadding"><span i18n>Confidence interval</span>:</div>
|
<div class="col-8 nopadding"><span i18n>Confidence interval</span>:</div>
|
||||||
<div class="col-4 pull-left nopadding">{{histogram.confidence * 100| number:'1.0-0'}}%</div>
|
<div class="col-4 pull-left nopadding">{{ getScaledValue(histogram.confidence * 100)| number:'1.0-0'}}%</div>
|
||||||
</ng-container>
|
</ng-container>
|
||||||
</div>
|
</div>
|
||||||
|
@ -14,6 +14,17 @@ export class HistogramDetailsComponent {
|
|||||||
@Input()
|
@Input()
|
||||||
histogram: IHistogram;
|
histogram: IHistogram;
|
||||||
|
|
||||||
|
@Input()
|
||||||
|
scale: number | null;
|
||||||
|
|
||||||
|
public getScaledValue(value: number): number {
|
||||||
|
let v = value;
|
||||||
|
if (this.scale && this.scale != 0) {
|
||||||
|
v = this.scale * value;
|
||||||
|
}
|
||||||
|
return v;
|
||||||
|
}
|
||||||
|
|
||||||
showConfidenceInterval(): boolean {
|
showConfidenceInterval(): boolean {
|
||||||
return this.histogram.confidence != null && this.histogram.confidence !== 1;
|
return this.histogram.confidence != null && this.histogram.confidence !== 1;
|
||||||
}
|
}
|
||||||
|
@ -35,7 +35,7 @@
|
|||||||
</ng-container>
|
</ng-container>
|
||||||
|
|
||||||
<ng-template #histogram>
|
<ng-template #histogram>
|
||||||
<fm-map-histogram-details [histogram]="layer.renderer.band.histogram"></fm-map-histogram-details>
|
<fm-map-histogram-details [histogram]="layer.renderer.band.histogram" [scale]="layer.scale"></fm-map-histogram-details>
|
||||||
</ng-template>
|
</ng-template>
|
||||||
</div>
|
</div>
|
||||||
</td>
|
</td>
|
||||||
|
Loading…
Reference in New Issue
Block a user