---
title: "判断数据是否服从均匀分布"
author: "William_Third"
date: "2016-09-29T09:12:23Z"
tags: []
categories: ["数据库"]
slug: "untitled"
draft: false
lastmod: "2016-09-29T09:12:23Z"
id: 2327733
url: "https://william-third.iteye.com/blog/2327733"
---

本程序用于判别所给数据源在置信率为 0.05 时的概率分布形式。A 的形式为n×1。 A=A(:);

 = unifit(A);
p1 = unifcdf(A, ahat, bhat);
 = kstest(A, , 0.05);

if h1==0
   disp('该数据源服从标准均匀分布。')

else

   disp('该数据源不服从标准均匀分布。')

end