• 大小: 678KB
    文件类型: .zip
    金币: 2
    下载: 0 次
    发布日期: 2024-01-04
  • 语言: Matlab
  • 标签: MATLAB  

资源简介

室内定位Matlab代码,基于RSSI强度、指纹库仿真代码,主要用于教学研究。

资源截图

代码片段和文件信息

function [Mean Ninedetail] = avgerror(kcheckerreflimitmode)
% Function to calculate average error nineteeth percentile error other
% details

% Input
% k                : k for kNN (k-Nearest Neighbour)
% validation_index : Row no. of validation data whose position is to determined
% checker          : Validation data
% ref              : training data

% mode             : 1 for FM 2 for WiFi 3 for both Fm and Wifi

% Output
% Mean             : Average error
% Nine             : Nineteeth percentile error
% detail           : (Column1Colum2)=> Actual coordinates
% (Column3Column4)=> Predicted Coordinated Column5 => Error

Mean=0;
error=zeros(1limit);
detail = zeros(limit5);
for i=1:limit
    fprintf(‘%3d %‘i);
    % Change posE to posM inorder to calculate for manhattan distance
    [error(i) p]=posE(kicheckerrefmode);
    detail(i1) = checker(i1);
    detail(i2) = checker(i2);
    detail(i3) = p(1);
    detail(i4) = p(2);
    detail(i5) = error(i);
    fprintf(‘\b\b\b\b‘);
end
error = sort(error);
Mean = mean(error);
nineth = floor(0.9*limit);
Nine = error(nineth);
end


 属性            大小     日期    时间   名称
----------- ---------  ---------- -----  ----
     目录           0  2017-09-05 07:48  Indoor-Localization-master\
     文件         571  2017-09-05 07:48  Indoor-Localization-master\FMDOOR.m
     文件        9085  2017-09-05 07:48  Indoor-Localization-master\Lineartraining.csv
     文件        1565  2017-09-05 07:48  Indoor-Localization-master\Linearvalidation.csv
     目录           0  2017-09-05 07:48  Indoor-Localization-master\Plots\
     文件       25056  2017-09-05 07:48  Indoor-Localization-master\Plots\cdfEuclidean.png
     文件       25248  2017-09-05 07:48  Indoor-Localization-master\Plots\cdfManhattan.png
     文件       20558  2017-09-05 07:48  Indoor-Localization-master\Plots\fmCDFplot.png
     文件       22414  2017-09-05 07:48  Indoor-Localization-master\Plots\fmCDFplotLINEAR.png
     文件      485470  2017-09-05 07:48  Indoor-Localization-master\Plots\fmDoor.png
     文件      225847  2017-09-05 07:48  Indoor-Localization-master\Plots\fmlog.png
     文件      406695  2017-09-05 07:48  Indoor-Localization-master\Plots\wifidoor.png
     文件         324  2017-09-05 07:48  Indoor-Localization-master\README.md
     文件         549  2017-09-05 07:48  Indoor-Localization-master\WIFIDOOR.m
     文件        1119  2017-09-05 07:48  Indoor-Localization-master\avgerror.m
     文件        3026  2017-09-05 07:48  Indoor-Localization-master\data.mat
     文件         763  2017-09-05 07:48  Indoor-Localization-master\fmLog.m
     文件         795  2017-09-05 07:48  Indoor-Localization-master\plotcdf.m
     文件        1127  2017-09-05 07:48  Indoor-Localization-master\plotcdfgrid.m
     文件        1486  2017-09-05 07:48  Indoor-Localization-master\posE.m
     文件        1487  2017-09-05 07:48  Indoor-Localization-master\posM.m
     文件       10126  2017-09-05 07:48  Indoor-Localization-master\ref.csv
     文件        2554  2017-09-05 07:48  Indoor-Localization-master\test.csv

评论

共有 条评论