- Add scripts/scoring/ module with normalizer, sensitivity analysis, and config - Enhance stock_viewer.html with standardized scoring display - Add integration tests and normalization verification scripts - Add documentation for standardization implementation and usage guides - Add data distribution analysis reports for strength scoring dimensions - Update discussion documents with algorithm optimization plans
42 lines
1018 B
Python
42 lines
1018 B
Python
"""
|
|
生成完整的敏感性分析报告
|
|
"""
|
|
|
|
import sys
|
|
import os
|
|
from pathlib import Path
|
|
|
|
# 添加路径
|
|
script_dir = Path(__file__).parent
|
|
sys.path.insert(0, str(script_dir))
|
|
|
|
from sensitivity import generate_full_sensitivity_report
|
|
from config import CONFIG_EQUAL
|
|
import pandas as pd
|
|
|
|
|
|
def main():
|
|
# 加载标准化数据
|
|
data_path = script_dir.parent.parent / 'outputs' / 'converging_triangles' / 'all_results_normalized.csv'
|
|
|
|
if not data_path.exists():
|
|
print(f"数据文件不存在: {data_path}")
|
|
print("请先运行 verify_normalization.py")
|
|
return
|
|
|
|
df = pd.read_csv(data_path)
|
|
print(f"加载数据: {len(df)} 条记录")
|
|
|
|
# 输出目录
|
|
output_dir = script_dir.parent.parent / 'outputs' / 'converging_triangles'
|
|
output_dir.mkdir(parents=True, exist_ok=True)
|
|
|
|
# 生成报告
|
|
generate_full_sensitivity_report(df, CONFIG_EQUAL, output_dir)
|
|
|
|
print("\n所有报告已生成完毕!")
|
|
|
|
|
|
if __name__ == "__main__":
|
|
main()
|