SmartCane/11_run_yield_prediction.ps1
2026-01-06 14:17:37 +01:00

27 lines
837 B
PowerShell

# 11_RUN_YIELD_PREDICTION.ps1
# ==========================
# PowerShell script to run yield prediction model comparison
# This compares CI-only vs CI+Ratoon models
#
# Usage: .\11_run_yield_prediction.ps1 [project_dir]
# - project_dir: Project directory name (default: esa)
param(
[string]$ProjectDir = "esa"
)
Write-Host "=== Running Yield Prediction Comparison ===" -ForegroundColor Cyan
Write-Host "Project: $ProjectDir"
Write-Host "Timestamp: $(Get-Date -Format 'yyyy-MM-dd HH:mm:ss')"
Write-Host ""
# Set R executable path
$RPath = "C:\Program Files\R\R-4.4.3\bin\x64\Rscript.exe"
# Run the R script
& $RPath "r_app\11_yield_prediction_comparison.R" $ProjectDir
Write-Host ""
Write-Host "=== Yield Prediction Comparison Complete ===" -ForegroundColor Green
Write-Host "Check output/reports/yield_prediction/ for results"