AI-driven tripartite classification for optimizing wearable bioelectronics in depression management.
Paper
Loaded from Europe PMC by your browser, not stored by OSCR: doi.org · Europe PMC
The paper is loaded when this pane is shown.
The authors' code
MATLAB · 961 lines · 41 KB · CC-BY-4.0
- classdef channel < handle
- %핸들 클래스는 object를 참조하는 객체를 정의합니다. 객체를 복사하면 동일한 객체에 대한 *참조*가 하나 더 생성됩니다.
- properties
- organoidNum
- channelNum
- month
- sf
- msPerTs
- nTimestamps
- startTime
- endTimeApprox
- durationApprox
- originalTime
- t
- raw
- filtered
- thres
- timestampsPrePeak
- timestampsPostPeak
- spikeTimestamps
- spikeTimestampsMatrix
- spikeWaveforms
- nSpikes
- PCScores
- explainedVar
- clusters
- nClusters
- nSpikesPerCluster
- totalMeanSpikeStruct
- meanSpikesStruct
- ISIbeforePCA
- ISI
- ISIStruct
- thetaWaves
- thetaPhases
- filteredwave
- filteredphase
- filteredangle
- spikefiltAngles
- saveCircularfilt
- spikeThetaAngles
- phaseStruct
- clusterColors
- bursts
- %EMG data analysis
- originalSignal
- % baseline filterd
- signalRawLowBaseline
- signalRawNoBaseline
- signalFilteredLowBaseline
- signalFilteredNoBaseline
- % Rectified
- rawRectified
- filteredRectified
- signalRawLowBaselineRectified
- signalRawNoBaselineRectified
- signalFilteredLowBaselineRectified
- signalFilteredNoBaselineRectified
- % Enveloped
- rawEnveloped
- filteredEnveloped
- signalRawLowBaselineEnveloped
- signalRawNoBaselineEnveloped
- signalFilteredLowBaselineEnveloped
- signalFilteredNoBaselineEnveloped
- % max values of enveloped
- rawEnvelopedMax
- filteredEnvelopedMax
- signalRawLowBaselineEnvelopedMax
- signalRawNoBaselineEnvelopedMax
- signalFilteredLowBaselineEnvelopedMax
- signalFilteredNoBaselineEnvelopedMax
- % phase analysis per frequency band
- spikeBandAngles
- bandWave
- bandPhase
- bandAmplitude
- %% for firing rate
- rawShuffled
- end
- methods
- function ch = channel(x, t, sampleRate, organoidNum, channelNum, month)%(*)
- % organoidNum, channelNum, month: 관리를 위한 index
- % 필요한 값 저장
- ch.organoidNum = organoidNum;
- ch.channelNum = channelNum;
- ch.month = month;
- ch.sf = sampleRate;
- ch.msPerTs = (1000 / sampleRate);
- % t related
- ch.originalTime = t;
- ch.t = t;
- ch.nTimestamps = length(t);
- ch.startTime = t(1);
- ch.endTimeApprox = t(end);
- ch.durationApprox = t(end) - t(1);
- % signals
- ch.originalSignal = x;
- ch.raw = x;
- ch.filtered = x; %일단 filtered에도 raw x를 저장해 놓음
- ch.clusterColors = ["red", "green", "blue", "magenta", "cyan", "yellow"]';
- % provide essential information to the user
- fprintf("channel number = %d\n", ch.channelNum)
- fprintf("sampling rate = %fHz\n", ch.sf)
- fprintf("starts at %f, ends at %f, duration = %f\n", ch.startTime, ch.endTimeApprox, ch.durationApprox)
- fprintf("number of timestamps = %d\n\n", ch.nTimestamps)
- end
- %% Preprocessing for EMG
- %% 1. cutting
- function cutTime(ch, timeInterval)
- [timestampStart, timestampEnd] = ch.getIntervalTimestamps(timeInterval);
- ch.t = ch.t(timestampStart : timestampEnd);
- ch.nTimestamps = length(ch.t);
- ch.startTime = ch.t(1);
- ch.endTimeApprox = ch.t(end);
- ch.durationApprox = ch.t(end) - ch.t(1);
- %raw와 filtered 모두 cut하고 각자 저장함
- ch.raw = ch.originalSignal(timestampStart : timestampEnd);% raw
- ch.filtered = ch.originalSignal(timestampStart : timestampEnd);% filtered
- %display info to the user
- fprintf("Reset all preprocessing of signals")
- fprintf("new startTime = %f\n", ch.startTime)
- fprintf("new endTime = %f\n", ch.endTimeApprox)
- fprintf("new duration = %f\n", ch.durationApprox)
- fprintf("new nTimestamp = %d\n", ch.nTimestamps)
- end % end of function cutTime
- %% 2. baseline filtering
- function filterBaseline(ch, baselineTimeIntervals, passBand)
- timeStampIntervals = ch.getMultipleIntervalTimestamps(baselineTimeIntervals);
- replacement = bandpass(ch.raw, passBand, ch.sf);
- ch.signalRawLowBaseline = ch.raw;
- ch.signalRawNoBaseline = ch.raw;
- for i = 1 : length(timeStampIntervals)
- intervalNow = timeStampIntervals{i};
- startStamp = intervalNow(1);
- endStamp = intervalNow(2);
- ch.signalRawLowBaseline(startStamp : endStamp) = replacement(startStamp : endStamp);
- ch.signalRawNoBaseline(startStamp : endStamp) = 0;
- end % end of for loop over timeStampIntervals
- ch.signalFilteredLowBaseline = ch.signalRawLowBaseline; %copy
- ch.signalFilteredNoBaseline = ch.signalRawNoBaseline; %copy
- end % end of method filterBaseline
- %% 3. signal filtering
- % bandpass filter
- function bandPass(ch, passBand)%(*)
- ch.filtered = bandpass(ch.filtered, passBand, ch.sf);
- end
- % butterworth high-pass filter
- function highPassButterworth(ch, order, cutoff)
- %cutoff of high-pass filter = lower bound
- Fn = (ch.sf/2); % Nyquist frequency
- ftype = "high";
- [b, a] = butter(order, cutoff/Fn, ftype);
- ch.filtered = filter(b,a,ch.filtered);
- ch.signalFilteredLowBaseline = filter(b,a,ch.signalFilteredLowBaseline);
- ch.signalFilteredNoBaseline = filter(b,a,ch.signalFilteredNoBaseline);
- end
- function notchButterworth(ch, order, notch)
- Fn = (ch.sf/2); % Nyquist frequency
- ftype = 'stop';
- [b, a] = butter(order, notch/Fn, ftype);
- ch.filtered = filter(b,a,ch.filtered);
- ch.signalFilteredLowBaseline = filter(b,a,ch.signalFilteredLowBaseline);
- ch.signalFilteredNoBaseline = filter(b,a,ch.signalFilteredNoBaseline);
- end
- %% 4. rectify
- function rectify(ch)
- ch.rawRectified = abs(ch.raw);
- ch.filteredRectified = abs(ch.filtered);
- ch.signalRawLowBaselineRectified = abs(ch.signalRawLowBaseline);
- ch.signalRawNoBaselineRectified = abs(ch.signalRawNoBaseline);
- ch.signalFilteredLowBaselineRectified = abs(ch.signalFilteredLowBaseline);
- ch.signalFilteredNoBaselineRectified = abs(ch.signalFilteredNoBaseline);
- end
- function envelope(ch, paramter, method)
- %enveloping
- [ch.rawEnveloped, lo] = envelope(ch.rawRectified, paramter, method);
- [ch.filteredEnveloped, lo] = envelope(ch.filteredRectified, paramter, method);
- [ch.signalRawLowBaselineEnveloped, lo] = envelope(ch.signalRawLowBaselineRectified, paramter, method);
- [ch.signalRawNoBaselineEnveloped, lo] = envelope(ch.signalRawNoBaselineRectified, paramter, method);
- [ch.signalFilteredLowBaselineEnveloped, lo] = envelope(ch.signalFilteredLowBaselineRectified, paramter, method);
- [ch.signalFilteredNoBaselineEnveloped, lo] = envelope(ch.signalFilteredNoBaselineRectified, paramter, method);
- %maxs
- ch.rawEnvelopedMax = max(ch.rawEnveloped);
- ch.filteredEnvelopedMax = max(ch.filteredEnveloped);
- ch.signalRawLowBaselineEnvelopedMax = max(ch.signalRawLowBaselineEnveloped);
- ch.signalRawNoBaselineEnvelopedMax = max(ch.signalRawNoBaselineEnveloped);
- ch.signalFilteredLowBaselineEnvelopedMax = max(ch.signalFilteredLowBaselineEnveloped);
- ch.signalFilteredNoBaselineEnvelopedMax = max(ch.signalFilteredNoBaselineEnveloped);
- end
- %% baseline
- function [timestampStart, timestampEnd] = getIntervalTimestamps(ch, timeInterval)
- startTime = timeInterval(1);
- endTime = timeInterval(2);
- % deal with edge cases
- if startTime < ch.startTime
- fprintf("Start time is earlier than the channel's first timestamp")
- return
- end
- if endTime > ch.endTimeApprox
- fprintf("End time is later than the channel's last timestamp")
- return
- end
- startDiff = startTime - ch.startTime;
- timestampStart = floor( (startDiff / (ch.msPerTs/1000) )) + 1;
- endDiff = ch.endTimeApprox - endTime;
- timestampEnd = length(ch.t) - floor( (endDiff / (ch.msPerTs/1000)) );
- end
- function timeStampIntervals = getMultipleIntervalTimestamps(ch, baselineTimeIntervals)
- timeStampIntervals = {};
- for i = 1 : length(baselineTimeIntervals)
- timeInterval = baselineTimeIntervals{i};
- [timestampStart, timestampEnd] = ch.getIntervalTimestamps(timeInterval);
- timeStampIntervals{i} = [timestampStart, timestampEnd];
- end
- end %end of method getIntervalTimestamps
- function timeStampIntervalsConcat = getIntervalTimestampsConcat(ch, timeIntervals)
- intervalsTimestamp = ch.getMultipleIntervalTimestamps(timeIntervals);
- firtInterval = intervalsTimestamp{1};
- timeStampIntervalsConcat = firtInterval(1):firtInterval(2);
- for i = 2:length(intervalsTimestamp)
- intervalNow = intervalsTimestamp{i};
- timeStampsNow = intervalNow(1) : intervalNow(2);
- timeStampIntervalsConcat = [timeStampIntervalsConcat, timeStampsNow];
- end
- end
- %% summary statistics
- function meanRMSValue = meanRMS(ch, timeIntervals)
- originalSignal = ch.originalSignal;
- timeStampIntervals = ch.getMultipleIntervalTimestamps(timeIntervals);
- for i = 1 : length(timeStampIntervals)
- intervalNow = timeStampIntervals{i};
- startStamp = intervalNow(1);
- endStamp = intervalNow(2);
- originalSignal(startStamp : endStamp) = 0;
- end
- meanRMSValue = mean(abs(originalSignal));
- end %end of method meanRMSValue
- function [pSignal, pNoise] = SNRValue(ch, signalIntervals, noiseIntervals)
- originalSignal = ch.originalSignal;
- timeStampSignal = ch.getIntervalTimestampsConcat(signalIntervals);
- timeStampNoise = ch.getIntervalTimestampsConcat(noiseIntervals);
- pSignal = rms(originalSignal(timeStampSignal));
- pNoise = rms(originalSignal(timeStampNoise));
- end %end of method SNRValue
- %%
- function detectSpikes(ch, thres, preTime, postTime)
- % from CyborgBrainOrg.m
- %주의:threshold에 minus가 붙어 있음, 즉 이 알고리즘은 local minimum을 찾는 알고리즘
- threshold = -thres.*median(abs(ch.filtered)/0.6745); % 표준편차를 근사하는 공식. outlier에 덜 민감
- ch.thres = threshold;
- ch.timestampsPrePeak = ceil(preTime * (ch.sf/1000)); % 발견된 spike peak 앞쪽으로 몇 timestamp만큼의 waveform을 저장해야 하는지 계산
- ch.timestampsPostPeak = ceil(postTime * (ch.sf/1000)); %발견된 spike peak 뒷쪽으로 몇 timestamp만큼의 waveform을 저장해야 하는지 계산
- ch.spikeTimestamps = []; % spike가 발견된 timestamp를 저장할 1d array
- ch.spikeWaveforms = []; % 앞에서 계산한 길이로 spike 앞뒤를 잘라 얻은 waveform을 각 row에 저장할 nd array
- % spike detection 수행
- ii = ch.timestampsPrePeak + 1;
- count = 0;
- while ii < ch.nTimestamps
- tmp = ch.filtered(ii);
- if tmp < threshold
- if ii + ch.timestampsPostPeak < ch.nTimestamps % spike가 뒷쪽에 있을 경우 waveformwidth가 확보될 때만 기록.
- count = count + 1;
- ch.spikeTimestamps(count) = ii;
- ch.spikeWaveforms(count,:) = ch.filtered((-ch.timestampsPrePeak : ch.timestampsPostPeak) + ii);
- end
- ii = ii + ch.timestampsPostPeak;
- else
- ii = ii + 1;
- end
- end
- ch.nSpikes = length(ch.spikeTimestamps); %발견한 spike 개수 저장
- fprintf('number of spikes found : %d\n', ch.nSpikes);
- ch.calculateTotalMeanSpikes(); %mean spike 계산 후 저장
- end %end of detectSpikes
- function detectSpikesPositive(ch, thres, preTime, postTime)
- % from CyborgBrainOrg.m
- %주의:threshold에 plus가 붙어 있음, 즉 이 알고리즘은 local maximum을 찾는 알고리즘
- threshold = thres.*median(abs(ch.filtered)/0.6745); %% 바꾼 부분 % 표준편차를 근사하는 공식. outlier에 덜 민감
- ch.timestampsPrePeak = ceil(preTime * (ch.sf/1000)); % 발견된 spike peak 앞쪽으로 몇 timestamp만큼의 waveform을 저장해야 하는지 계산
- ch.timestampsPostPeak = ceil(postTime * (ch.sf/1000)); %발견된 spike peak 뒷쪽으로 몇 timestamp만큼의 waveform을 저장해야 하는지 계산
- ch.spikeTimestamps = []; % spike가 발견된 timestamp를 저장할 1d array
- ch.spikeWaveforms = []; % 앞에서 계산한 길이로 spike 앞뒤를 잘라 얻은 waveform을 각 row에 저장할 nd array
- % spike detection 수행
- ii = ch.timestampsPrePeak + 1;
- count = 0;
- while ii < ch.nTimestamps
- tmp = ch.filtered(ii);
- if tmp > threshold %%바꾼 부분
- if ii + ch.timestampsPostPeak < ch.nTimestamps % spike가 뒷쪽에 있을 경우 waveformwidth가 확보될 때만 기록.
- count = count + 1;
- ch.spikeTimestamps(count) = ii;
- ch.spikeWaveforms(count,:) = ch.filtered((-ch.timestampsPrePeak : ch.timestampsPostPeak) + ii);
- end
- ii = ii + ch.timestampsPostPeak;
- else
- ii = ii + 1;
- end
- end
- ch.nSpikes = length(ch.spikeTimestamps); %발견한 spike 개수 저장
- fprintf('number of spikes found : %d\n', ch.nSpikes);
- ch.calculateTotalMeanSpikes(); %mean spike 계산 후 저장
- end %end of detectSpikesPositive
- function getPCScores(ch)
- % from CyborgBrainOrg.m
- waveformZ = zscore(ch.spikeWaveforms); %standard scaling
- [~,score,~,~,explained] = pca(waveformZ); % waveform들에 PCA 적용
- ch.PCScores = score(:,1:2); % pick first two PC scores
- ch.explainedVar = explained; % PC의 분산 설명량 저장
- end
- function getKmeansClusters(ch, clusternum, seednum)
- % from CyborgBrainOrg.m
- rng(seednum); % 시드 넘버 설정
- [clusters, centroid] = kmeans(ch.PCScores, clusternum);%주어진 cluster개수로 kmeans 실행
- ch.clusters = clusters; %클러스터 membership 저장
- ch.nClusters = clusternum; %클러스터 개수 저장
- % 클러스터당 spike 개수
- ch.nSpikesPerCluster = zeros([ch.nClusters,1]);
- for ii = 1 : length(ch.clusters)
- for c = 1 : ch.nClusters
- if ch.clusters(ii) == c
- ch.nSpikesPerCluster(c) = ch.nSpikesPerCluster(c) + 1;
- ch.spikeTimestampsMatrix(c, ch.nSpikesPerCluster(c)) = ch.spikeTimestamps(ii);
- end
- end
- end
- % 클러스터별 spike 개수를 사용자에게 출력해 주기
- disp("number of spikes per cluster:")
- for clusterNum = 1 : length(ch.nSpikesPerCluster)
- fprintf("cluaster %d: %d \n", clusterNum, ch.nSpikesPerCluster(clusterNum))
- end
- ch.calculateClusterMeanSpikes() %클러스터별로 meanSpike, S.D. 계산
- %클러스터별로 InterSpike Intervals 계산. 각 클러스터별로 spike가 두 개 이상이어야 함
- if sum(ch.nSpikesPerCluster<=1) == 0
- ch.calculateISI()
- else
- disp("mean spike와 sd는 계산되었으나, spike가 한 개 이하인 클러스터가 존재하므로 클러스터별 ISI를 계산할 수 없습니다. ISI를 계산하려면 seed number를 다르게 하거나, 클러스터 개수를 다르게 해야 합니다.")
- end
- end % end of getKmeansClusters
- function getThetas(ch)%(*)
- ch.thetaWaves = bandpass(ch.raw, [4, 8], ch.sf); %apply 4-8 Hz frequency band
- xHilbert = hilbert(ch.thetaWaves); % Hilbert transform하여 복소수 형태로 표현
- ch.thetaPhases = angle(xHilbert); % 실수부와 허수부 사이 각을 계산
- ch.spikeThetaAngles = ch.thetaPhases(ch.spikeTimestamps); %spike 발생 시점의 theta angle을 저장
- ch.saveCircularTheta() %cluster별로 나누어 theta phase 값을 저장
- end %end of getThetas
- function getfilteredwave(ch,passBands)%(*)
- ch.filteredwave = bandpass(ch.raw, passBands, ch.sf); %apply a-b Hz frequency band
- xHilberts = hilbert(ch.filteredwave); % Hilbert transform하여 복소수 형태로 표현
- ch.filteredphase = angle(xHilberts); % 실수부와 허수부 사이 각을 계산
- ch.filteredangle = 57.29578 * ch.filteredphase;
- ch.spikefiltAngles = ch.filteredphase(ch.spikeTimestamps); %spike 발생 시점의 theta angle을 저장
- ch.saveCircularfilt(); %cluster별로 나누어 theta phase 값을 저장
- end %end of getThetas
- function [bandWaveOut, bandPhaseOut] = getBand(ch, frequencyRange)
- % added 2023.06.06
- % slightly modified the function getThetas
- % for the request "LFP-SU joint analysis"
- % input:
- % 1. freqBand: array of two numbers e.g. [4, 8]
- % - frequency band used for bandpass filter
- %
- % output:
- % 1. bandWave: 1d array.
- % - filtered voltage
- % 2. bandPhase: 1d array.
- % - filtered phase
- ch.bandWave = bandpass(ch.raw, frequencyRange, ch.sf); %uses the raw signal, so the function do not applies iteratively.
- analytic_signal = hilbert(ch.bandWave); % Hilbert transform하여 복소수 형태로 표현
- ch.bandAmplitude = abs(analytic_signal);
- ch.bandPhase = angle(analytic_signal); % 실수부와 허수부 사이 각을 계산
- ch.spikeBandAngles = ch.bandPhase(ch.spikeTimestamps); %spike 발생 시점의 angle을 저장
- ch.saveCircularBand() %cluster별로 나누어 phase 값을 저장
- %output
- bandWaveOut = ch.bandWave;
- bandPhaseOut = ch.bandPhase;
- end %end of function getBand
- function saveCircularBand(ch)%(*)
- for c = 1 : ch.nClusters
- ch.phaseStruct(c).values = ch.spikeBandAngles(ch.clusters == c); %timestamp 단위를 milisecond 단위로 변환
- ch.phaseStruct(c).clusterNum = c;%클러스터 번호 저장
- ch.phaseStruct(c).nSpikes = ch.nSpikesPerCluster(c);% 클러스터 내 spike 개수 저장
- end
- end % saveCircularBand
- function [phaseValues, nSpikes] = getBandPhaseByClusterNum(ch, clusterNum)%(*)
- %주어진 clusterNum에 해당하는 클러스터의 theta phase 값을 가져오는 함수. 히스토그램 그릴 때
- %쓰는 데이터를 얻기 위해 사용
- phaseValues = ch.phaseStruct(clusterNum).values;
- nSpikes = ch.phaseStruct(clusterNum).nSpikes;
- end % end of getBandPhaseByClusterNum
- function uniformTest(ch)
- pvals = zeros([ch.nClusters,1]);
- for c = 1 : ch.nClusters
- angles = ch.spikeBandAngles(ch.clusters == c);
- [pval, z] = circ_rtest(angles);
- pvals(c) = pval;
- end
- pvals
- end
- function uniformTest2(ch)
- pvalue = zeros(ch)
- for c=1:ch
- angles = ch.spikefiltAngles(ch)
- [pval, z] = circ_rtest(angles);
- pvalue(c) = pval;
- end
- pavlue;
- end
- % drawing functions
- function calculateTotalMeanSpikes(ch)
- %통합 mean spike
- tRangeCentered = (-ch.timestampsPrePeak : ch.timestampsPostPeak) * ch.msPerTs; %각 waveform의 t range. spike위치가 0이 되게 centering되어 있고, milisecond 단위로 변환
- %meanSpike를 정의
- if ch.nSpikes > 1 % 전체 spike 개수가 2개 이상이면
- meanSpike = mean(ch.spikeWaveforms); %모든 spike의 waveform을 평균한 것이 meanSpike
- else %전체 spike 개수가 1개 뿐이면
- meanSpike = ch.spikeWaveforms;% 굳이 mean을 계산할 필요 없이 그 spike가 곧 meanSpike
- end
- stdSpikes = std(ch.spikeWaveforms);
- ch.totalMeanSpikeStruct.nSpikes = ch.nSpikes; % cluster 내 spike 개수 저장
- ch.totalMeanSpikeStruct.meanSpike = meanSpike; % meanSpike waveform 저장
- ch.totalMeanSpikeStruct.std = stdSpikes;% standard deviation 저장
- ch.totalMeanSpikeStruct.tRangeCentered = tRangeCentered; %waveform의 t range 저장
- end %end of calculateTotalMeanSpikes
- function calculateClusterMeanSpikes(ch)
- % from CyborgBrainOrg.m
- % for each cluster, calculate average waveform, and S.D.;
- tRangeCentered = (-ch.timestampsPrePeak : ch.timestampsPostPeak) * ch.msPerTs; %각 waveform의 t range. spike위치가 0이 되게 centering되어 있고, milisecond 단위로 변환
- for c = 1 : ch.nClusters %각 클러스터마다 반복
- nSpikesNow = sum(ch.clusters == c);% 클러스터 내 spike 개수 저장
- spikesNow = ch.spikeWaveforms((ch.clusters == c),:); %현 cluster 내 spike waveform만 모은 행렬
- stdSpikes = std(ch.spikeWaveforms((ch.clusters == c),:));% 표준편차 계산
- %meanSpike를 정의
- if nSpikesNow > 1 % 클러스터 내에 spike 개수가 2개 이상이면
- meanSpike = mean(spikesNow); %모든 spike의 waveform을 평균한 것이 meanSpike
- else %클러스터 내에 spike 개수가 1개 뿐이면
- meanSpike = spikesNow;% 굳이 mean을 계산할 필요 없이 그 spike가 곧 meanSpike
- end
- % 구조체에 클러스터별 데이터 저장장
- ch.meanSpikesStruct(c).nSpikes = nSpikesNow; % cluster 내 spike 개수 저장
- ch.meanSpikesStruct(c).meanSpike = meanSpike; % meanSpike waveform 저장
- ch.meanSpikesStruct(c).std = stdSpikes;% standard deviation 저장
- ch.meanSpikesStruct(c).tRangeCentered = tRangeCentered; %waveform의 t range 저장
- end
- end % end of calculateClusterMeanSpikes
- function [meanSpikeWaveform, std, tRangeCentered, nSpikes] = getTotalMeanSpike(ch)
- meanSpikeWaveform = ch.totalMeanSpikeStruct.meanSpike;
- std = ch.totalMeanSpikeStruct.std;
- tRangeCentered = ch.totalMeanSpikeStruct.tRangeCentered;
- nSpikes = ch.totalMeanSpikeStruct.nSpikes;
- end %end of getTotalMeanSpike
- function [meanSpikeWaveform, std, tRangeCentered, nSpikes] = getClusterMeanSpike(ch, clusterNum)
- meanSpikeWaveform = ch.meanSpikesStruct(clusterNum).meanSpike;
- std = ch.meanSpikesStruct(clusterNum).std;
- tRangeCentered = ch.meanSpikesStruct(clusterNum).tRangeCentered;
- nSpikes = ch.meanSpikesStruct(clusterNum).nSpikes;
- end %end of getClusterMeanSpike
- function drawRaster(ch, color)
- % from CyborgBrainOrg.m
- for ii = 1:length(ch.spikeTimestamps)
- spikeTimestampTuple = ch.startTime + [ch.spikeTimestamps(ii), ch.spikeTimestamps(ii)]/ch.sf;
- p = plot(spikeTimestampTuple, [-1,1], 'k');
- p.Color = color;
- hold on
- end
- hold off
- ylim([-2, 2]);
- title('Raster plot');
- xlabel('time(s)');
- ylabel('Raster');
- end %drawRaster
- function drawColoredRaster(ch, clusterColors)
- % from CyborgBrainOrg.m
- for ii = 1 : length(ch.clusters)
- if ch.clusters(ii) == 1
- clusterNum = ch.clusters(ii);
- spikeTimestampTuple = ch.startTime + [ch.spikeTimestamps(ii), ch.spikeTimestamps(ii)]/ch.sf;
- plot(spikeTimestampTuple,[-1,1], clusterColors(clusterNum));
- hold on
- elseif ch.clusters(ii) == 2
- clusterNum = ch.clusters(ii);
- spikeTimestampTuple = ch.startTime + [ch.spikeTimestamps(ii), ch.spikeTimestamps(ii)]/ch.sf;
- plot(spikeTimestampTuple,[-1,1], clusterColors(clusterNum));
- hold on
- elseif ch.clusters(ii) == 3
- clusterNum = ch.clusters(ii);
- spikeTimestampTuple = ch.startTime + [ch.spikeTimestamps(ii), ch.spikeTimestamps(ii)]/ch.sf;
- plot(spikeTimestampTuple,[-1,1], clusterColors(clusterNum));
- hold on
- elseif ch.clusters(ii) == 4
- clusterNum = ch.clusters(ii);
- spikeTimestampTuple = ch.startTime + [ch.spikeTimestamps(ii), ch.spikeTimestamps(ii)]/ch.sf;
- plot(spikeTimestampTuple,[-1,1], clusterColors(clusterNum));
- hold on
- elseif ch.clusters(ii) == 5
- clusterNum = ch.clusters(ii);
- spikeTimestampTuple = ch.startTime + [ch.spikeTimestamps(ii), ch.spikeTimestamps(ii)]/ch.sf;
- plot(spikeTimestampTuple,[-1,1], clusterColors(clusterNum));
- hold on
- end
- end
- ylim([-2,2]);
- hold off
- end % drawColoredRaster
- function ISIbeforePCA = getISIvaluesBeforePCA(ch)
- ch.ISIbeforePCA = diff(ch.spikeTimestamps);
- ISIbeforePCA = ch.ISIbeforePCA * ch.msPerTs;
- end % end of getISIvaluesBeforePCA
- function calculateISI(ch)
- % from CyborgBrainOrg.m
- %calculate ISI
- for c = 1 : ch.nClusters
- for j = 2 : ch.nSpikesPerCluster(c)
- if ch.spikeTimestampsMatrix(c, j) > 0
- ch.ISI(c,j) = ch.spikeTimestampsMatrix(c, j) - ch.spikeTimestampsMatrix(c, j - 1);
- end
- end
- end
- ch.ISI(:, 1) = [];
- %클러스터별 ISI 값을 구조체(struct)에 저장
- for c = 1 : ch.nClusters %cluster 1부터 마지막 cluster까지 반복. c가 클러스터 번호
- ch.ISIStruct(c).values = ch.ISI(c, 1 : ch.nSpikesPerCluster(c) - 1) * ch.msPerTs; %timestamp 단위를 milisecond 단위로 변환
- ch.ISIStruct(c).clusterNum = c;%클러스터 번호 저장
- ch.ISIStruct(c).nSpikes = ch.nSpikesPerCluster(c);% 클러스터 내 spike 개수 저장
- end
- end % end of calculateISI
- function [ISIvalues, nSpikes] = getISIvalues(ch, clusterNum)
- ISIvalues = ch.ISIStruct(clusterNum).values;
- nSpikes = ch.ISIStruct(clusterNum).nSpikes;
- end %end of getISIvalues
- function bursts = detectBurstsMI(ch, begISI, endISI, minSpikes, minDurn, minIBI)
- % input:
- % - one spike train
- % - begISI : maximum interval to start burst; max ISI at start of burst; Beginning inter spike interval
- % - endISI : maximum interval to end burst; max ISI in burst; Ending inter spike interval
- % - minIBI: minimum interval between bursts (threshold for combining bursts)
- % - minDurn: minimum duration of a burst; minimum duration to consider as burst
- % - minSpikes: minimum number of spikes in burst; minimum number of spikes to consider as burst
- % output: bursts found using max interval method.
- msPerTs = ch.msPerTs;
- nspikes = ch.nSpikes;
- spikes = ch.spikeTimestamps;
- spikes = spikes * msPerTs;
- % Create a temp array for the storage of the bursts.
- % Assume that it will not be longer than Nspikes/2
- % since we need at least two spikes to be in a burst.
- maxBursts = floor(nspikes/2);
- bursts = NaN(maxBursts, 3);
- bursts = array2table(bursts, 'VariableNames',{'beg','end','IBI'});
- noBursts = []; %value to return if no bursts found.
- burst = 0; % current burst number
- %Start of the main algorithm
- % Phase 1 -- burst detection.
- %
- % parameters used: begISI, endISI
- %
- % when two consecutive spikes have an ISI *less* than begISI apart.
- % i.e. if nextISI < begISI,
- % a burst is defined as starting.
- %
- % The end of the burst is given
- % when two spikes have an ISI *greater* than endISI,
- % i.e. if nextISI > endISI.
- % in short, we find ISIs closer than begISI, and end with endISI.
- % lastEnd is the time of the last spike in the previous burst.
- % This is used to calculate the IBI.
- % For the first burst, this is no previous IBI
- lastEnd = NaN; %for first burst, there is no IBI.
- n = 2;
- isInBurst = false;
- while n <= nspikes
- nextISI = spikes(n) - spikes(n-1);
- if isInBurst
- % end of burst
- if nextISI > endISI
- endStamp = n - 1;
- isInBurst = false;
- ibi = spikes(beg) - lastEnd;
- lastEnd = spikes(endStamp);
- res = [beg, endStamp, ibi];
- burst = burst + 1;
- % fail case
- if burst > maxBursts
- print("too many bursts!!! algorithm failed.")
- return
- end %end of {if burst > maxBursts}
- bursts(burst, : ) = array2table(res);
- end % end of {nextISI > endISI}
- else % else of {if isInBurst}, i.e. not yet in burst
- % Found the start of a new burst.
- if nextISI < begISI
- beg = n - 1;
- isInBurst = true;
- end % end of {nextISI < begISI}
- end % end of {if isInBurst}
- n = n + 1;
- end %end of while n <= nspikes
- %phase 1.1. At the end of the burst, check if we were in a burst when the train finished.
- if isInBurst
- endStamp = nspikes;
- ibi = spikes(beg) - lastEnd;
- res = [beg, endStamp, ibi];
- burst = burst + 1;
- % fail case
- if burst > maxBursts
- print("too many bursts!!! algorithm failed.")
- return
- end % end of if burst > maxBursts
- bursts(burst , :) = array2table(res);
- end % end of if isInBurst
- %phase 1.2. Check if any bursts were found.
- if burst > 0
- % truncate to right length, as bursts will typically be very long.
- % (since we initated bursts with nrow = maxBursts)
- bursts = bursts(1:burst, :);
- else
- %% no bursts were found, so return an empty structure.
- print("no bursts were found. algorithm failed.")
- return
- end %end of {burst > 0}
- %print results
- nBurstsPhase1 = size(bursts);
- nBurstsPhase1 = nBurstsPhase1(1);
- fprintf("phase 1 result: found %d bursts, using parameters begISI and endISI\n\n", nBurstsPhase1)
- %bursts
- % Phase 2 -- merging of bursts.
- %
- % parameters used : minIBI
- %
- % Here we see if any pair of bursts have an IBI *less* than minIBI;
- % if so, we then merge the bursts.
- % We specifically need to check when say three bursts are merged into one.
- ibis = bursts(: ,'IBI');
- ibis = table2array(ibis);
- isMergeNeeded = ibis < minIBI;
- isAnyMergeNeeded = logical(sum(isMergeNeeded));
- if isAnyMergeNeeded
- % Merge bursts efficiently.
- % Work backwards through the list,
- % and then delete the merged lines afterwards.
- % This works when we have say 3+ consecutive bursts that merge into one.
- mergeIndex = find(isMergeNeeded);
- mergeIndexRev = flip(mergeIndex)
- for j = mergeIndexRev
- burst = mergeIndexRev(j);
- bursts(burst-1, "end") = bursts(burst, "end") %move the information one step forward.
- bursts(burst , "end") = NaN %not needed, but helpful.
- end %end or for loop
- bursts = bursts(not(isMergeNeeded) , : ) % delete the unwanted info.
- end % end of {sum(mergeBursts) > 1}
- nBurstsPhase2 = size(bursts);
- nBurstsPhase2 = nBurstsPhase2(1);
- fprintf("phase 2 result: after merging by minIBI, %d bursts left\n\n", nBurstsPhase2)
- % bursts
- % Phase 3 -- remove small bursts
- %
- % parameters used : minDurn, minSpikes
- %
- % delete small bursts i.e.
- % less than min duration (minDurn), or
- % having too few spikes (less than minSpikes).
- % In this phase we have the possibility of deleting all spikes.
- % LEN = number of spikes in a burst.
- % DURN = duration of burst.
- bursts = table2array(bursts);
- len = bursts(: , 2) - bursts(: , 1) + 1; %end, beg
- durn = spikes(bursts(: , 2)) - spikes(bursts(: , 1)); %end, beg
- bursts = [bursts, len, durn'];
- bursts = array2table(bursts, 'VariableNames',{'beg','end','IBI', 'len', 'durn'});
- IsReject = ((durn' < minDurn) | ( len < minSpikes));
- isAnyRejects = logical(sum(IsReject));
- fprintf("phase 3 result: %d bursts were removed whose duration is less than %d milisecond or have spikes less than %d ", sum(IsReject), minDurn, minSpikes)
- rejectsIndex = find(IsReject);
- % delete small bursts
- if isAnyRejects
- bursts = bursts(not(IsReject) , : );
- end % end of if isAnyRejects
- nBursts = size(bursts);
- nBursts = nBursts(1);
- if nBursts == 0 % if all the bursts were removed during phase 3.
- bursts = noBursts;
- else % else of {nBursts == 0}
- % Compute mean ISIS
- bursts = table2array(bursts);
- len = bursts(: , 2) - bursts(: , 1) + 1; %end, beg
- durn = spikes( bursts(: , 2) ) - spikes( bursts(: , 1) ); %end, beg
- meanISI = durn' ./ (len-1);
- % Recompute IBI (only needed if phase 3 deleted some cells).
- if nBursts > 1
- ibiBeg = spikes( bursts(: , 1) ); %beg
- ibiBeg = ibiBeg(2:nBursts);
- ibiEnd = spikes( bursts(: , 2) ); %end
- ibiEnd = ibiEnd(1:(nBursts-1));
- ibi2 = ibiBeg - ibiEnd;
- ibi2 = [NaN; ibi2'];
- else
- ibi2 = NaN;
- end
- bursts(: ,3) = ibi2; %IBI
- bursts = [bursts, meanISI];
- bursts = array2table(bursts, 'VariableNames',{'beg','end','IBI', 'nSpikes', 'durn', 'meanISI'});
- end %end of {if nBursts == 0}
- ch.bursts = bursts;
- end %end of the function
- function saveCircularTheta(ch)%(*)
- for c = 1 : ch.nClusters
- ch.phaseStruct(c).values = ch.spikeThetaAngles(ch.clusters == c); %timestamp 단위를 milisecond 단위로 변환
- ch.phaseStruct(c).clusterNum = c;%클러스터 번호 저장
- ch.phaseStruct(c).nSpikes = ch.nSpikesPerCluster(c);% 클러스터 내 spike 개수 저장
- end
- end % saveCircularTheta
- function [phaseValues, nSpikes] = getThetaPhaseByClusterNum(ch, clusterNum)%(*)
- %주어진 clusterNum에 해당하는 클러스터의 theta phase 값을 가져오는 함수. 히스토그램 그릴 때
- %쓰는 데이터를 얻기 위해 사용
- phaseValues = ch.phaseStruct(clusterNum).values;
- nSpikes = ch.phaseStruct(clusterNum).nSpikes;
- end % end of getThetaPhaseByClusterNum
- %% for test purpose
- function shuffle(ch, nfold)
- % add random noise to the raw signal to imitate
- nSample = length(ch.raw);
- nSamplePerFold = fix(nSample / nfold);
- nSampleRemain= rem(nSample, nfold);
- fold_index = {};
- for i = 1 : nfold
- fold_index{i} = ((i-1) * nSamplePerFold + 1) : (i * nSamplePerFold);
- end
- p = randperm(nfold);
- for i = 1 : nfold
- random_integer = p(i);
- raw_index = fold_index{i};
- random_index = fold_index{random_integer};
- ch.raw(raw_index) = ch.raw(random_index);
- end
- ch.filtered = ch.raw;
- end
- %%
- function [MI,MeanAmp] = ModIndex_v1(lfp,srate,Pf1,Pf2,Af1,Af2,position)
- % the eegfilt routine employed below is obtained from the EEGLAB toolbox
- % (Delorme and Makeig J Neurosci Methods 2004)
- PhaseFreq=eegfilt(lfp,srate,Pf1,Pf2); % this is just filtering
- Phase=angle(hilbert(PhaseFreq)); % this is getting the phase time series
- AmpFreq=eegfilt(lfp,srate,Af1,Af2); % just filtering
- Amp=abs(hilbert(AmpFreq)); % getting the amplitude envelope
- % Now we search for a Phase-Amp relation between these frequencies by
- % caclulating the mean amplitude of the AmpFreq in each phase bin of the
- % PhaseFreq
- % Computing the mean amplitude in each phase:
- nbin=length(position);
- winsize = 2*pi/nbin;
- MeanAmp=zeros(1,nbin);
- for j=1:nbin
- I = find(Phase < position(j)+winsize & Phase >= position(j));
- MeanAmp(j)=mean(Amp(I));
- end
- % the center of each bin (for plotting purposes) is position+winsize/2
- % quantifying the amount of amp modulation by means of a
- % normalized entropy index (Tort et al PNAS 2008):
- MI=(log(nbin)-(-sum((MeanAmp/sum(MeanAmp)).*log((MeanAmp/sum(MeanAmp))))))/log(nbin);
- end
- end %methods
- end %class
channel.m, under CC-BY-4.0 · at the source
Overview
- Department of Materials Science and Engineering, Yonsei University College of Engineering, Seoul 03722, Republic of Korea
- Center for Nanomedicine, Institute for Basic Science (IBS), Seoul 03722, Republic of Korea
- Department of Nano Biomedical Engineering (NanoBME), Advanced Science Institute, Yonsei University, Seoul 03722, Republic of Korea
- Department of Neurosurgery, Yonsei University College of Medicine, Seoul 03722, Republic of Korea
- Yonsei-KIST Convergence Research Institute, Seoul 03722, Republic of Korea
Abstract
Current disease-sensing devices primarily focus on distinguishing between healthy and diseased states, effective for diagnosis but limited in guiding optimal intervention timing for prevention. We developed a tripartite framework identifying pre-disease state in depression, a reversible phase preceding irreversible onset. Using complex systems theory, we analyzed early-warning signals emerging as biological systems approach critical transitions. Continuous monitoring of nine multimodal biomarkers—spanning electrophysiological, behavioral, and biological—enabled classification into normal, pre-disease, and disease states by quantitatively defining critical points. An artificial intelligence agent classified disease states with 95.2% accuracy using multimodal data, enabled by ultrasoft neural probes for stable, low-damage recordings. Therapeutic validation with a skin-attachable wireless vagus nerve stimulator integrating soft three-dimensional electrodes demonstrated superior efficacy during pre-disease states. Subjects treated during pre-disease showed faster recovery and greater therapeutic responses, while those treated after disease onset failed to achieve full recovery. This framework provides evidence-based rationale for early intervention.
Reproduced under the paper's license (CC BY-NC), from the paper cited above.
Repository
Its files are read in the Code ↔ Paper reader above.
figshare 31813771
Availability: 1 check, the latest on 27 September 2026: the link answers (HTTP 200)
- 27 September 2026: the link answers (HTTP 200)
3 files
- Customized MATLAB code.zip/
Coherence analysis.mlx , MATLAB, not shown here - Customized MATLAB code.zip/
Phaselocking analysis.mlx , MATLAB, not shown here - Customized MATLAB code.zip/
channel.m , MATLAB, 961 lines
The paper's code and data availability statement is in the Data section.
Tracing map
Proposed by the machine: these links were found in the paper and verified at the source, without human review. The map will receive a Zenodo DOI once one of the paper's authors has validated it with their ORCID.
What the map holds:
- 1 repository of the authors' code, each at its verified commit, with its license and how the link was found in the paper;
- 3 scripts, each with its path and the digest of its content;
- no match between paragraphs and code yet;
- neither the text of the paper nor the code itself.
Its JSON (tracing-map.json) is deposited on Zenodo with its DOI once the map is validated.
Data
No dataset and no data link were found in the paper.
Data, code, and materials availability
This study did not generate new materials. All data and code needed to evaluate and reproduce the results in the paper are present in the paper and/
Reproduced under the paper's license (CC BY-NC), from the paper cited above.
Versions
The history of this record: each version stored by the harvester or made by a correction of its authors or of the maintainers of its code, and what changed in its facts. The texts of the paper (its abstract, its availability statements) are not part of it; versions that changed only those are not listed.
Version 1, 27 September 2026: the first record
Recorded: type, language, journal, volume, issue, pages, dates, 9 authors, 8 MeSH terms, 4 funders, 52 references.
Cite
This paper
Lee, J., Hong, Y.-M., Kim, E., Seo, H., Chung, W. G., Park, W., Song, H., Kim, S., & Park, J.-U. (2026). AI-driven tripartite classification for optimizing wearable bioelectronics in depression management. Science advances, 12(26), eaec9837. https://
BibTeX
@article{lee2026ai,
author = {Lee, Jakyoung and Hong, Yeon-Mi and Kim, Enji and Seo, Hunkyu and Chung, Won Gi and Park, Wonjung and Song, Hayoung and Kim, Sumin and Park, Jang-Ung},
title = {{AI-driven tripartite classification for optimizing wearable bioelectronics in depression management}},
journal = {Science advances},
year = {2026},
month = jun,
volume = {12},
number = {26},
pages = {eaec9837},
publisher = {American Association for the Advancement of Science},
issn = {2375-2548},
doi = {10.1126/
url = {https://
pmid = {42341109},
pmcid = {PMC13292945}
}
RIS
TY - JOUR
AU - Lee, Jakyoung
AU - Hong, Yeon-Mi
AU - Kim, Enji
AU - Seo, Hunkyu
AU - Chung, Won Gi
AU - Park, Wonjung
AU - Song, Hayoung
AU - Kim, Sumin
AU - Park, Jang-Ung
TI - AI-driven tripartite classification for optimizing wearable bioelectronics in depression management
T2 - Science advances
J2 - Sci Adv
PY - 2026
DA - 2026/
VL - 12
IS - 26
SP - eaec9837
SN - 2375-2548
PB - American Association for the Advancement of Science
DO - 10.1126/
UR - https://
LA - en
ER -
CSL-JSON
{
"id": "10.1126/
"type": "article-journal",
"title": "AI-driven tripartite classification for optimizing wearable bioelectronics in depression management",
"container-title": "Science advances",
"author": [
{
"family": "Lee",
"given": "Jakyoung"
},
{
"family": "Hong",
"given": "Yeon-Mi"
},
{
"family": "Kim",
"given": "Enji"
},
{
"family": "Seo",
"given": "Hunkyu"
},
{
"family": "Chung",
"given": "Won Gi"
},
{
"family": "Park",
"given": "Wonjung"
},
{
"family": "Song",
"given": "Hayoung"
},
{
"family": "Kim",
"given": "Sumin"
},
{
"family": "Park",
"given": "Jang-Ung"
}
],
"container-title-short":
"volume": "12",
"issue": "26",
"page": "eaec9837",
"DOI": "10.1126/
"PMID": "42341109",
"PMCID": "PMC13292945",
"ISSN": "2375-2548",
"publisher": "American Association for the Advancement of Science",
"URL": "https://
"language": "en",
"issued": {
"date-parts": [
[
2026,
6,
24
]
]
}
}
The tracing map gets a citation of its own once an author has validated it and it has a DOI.
Similar papers
The papers with a page that share the most with this one: the tools found in their code, their categories, datasets, cited references and authors, the rarest counting most.
- [1] doi:10.1038/s41467-026-75244-w [code]
- Neural dynamics of temporal interference stimulation monitoring by soft liquid metal interfaces across neural systems.Journal: Nature communicationsIn common: 8 references, 2 authors
- [2] doi:10.1371/journal.pbio.3003938 [code]
- Theta oscillations tag episodic memories for sleep-dependent consolidation.Journal: PLoS biologyIn common: CircStat, EEGLAB, Signal Processing Toolbox, 1 other tool
- [3] doi:10.1371/journal.pbio.3003818 [code]
- Human neuronal firing varies with the frequency of local field potential oscillations.Journal: PLoS biologyIn common: CircStat, EEGLAB, Signal Processing Toolbox, 1 other tool
- [4] doi:10.1523/jneurosci.0154-26.2026 [code]
- Faster but less precise: expectation enhances response speed while reducing sensory fidelity.Journal: The Journal of neuroscience : the official journal of the Society for NeuroscienceIn common: CircStat, EEGLAB, Signal Processing Toolbox, 1 other tool
- [5] doi:10.1162/imag.a.1229 [code]
- 40 Hz audiovisual stimulation improves sustained attention and related brain oscillations.Journal: Imaging neuroscience (Cambridge, Mass.)In common: CircStat, EEGLAB, Signal Processing Toolbox, 1 other tool
- [6] doi:10.1038/s41598-026-49900-6 [code]
- Global neural oscillations underlie performance variability and attentional state fluctuations in humans.Journal: Scientific reportsIn common: CircStat, EEGLAB, Signal Processing Toolbox, 1 other tool
- [7] doi:10.7554/elife.110795 [code]
- REM sleep prefrontal high-frequency oscillation chains mediate distinct cortical - hippocampal reactivation patterns compared to NREM sleep.Journal: eLifeIn common: CircStat, EEGLAB, Signal Processing Toolbox, 1 other tool
- [8] doi:10.1523/jneurosci.2001-25.2026 [code]
- Dynamics of Dentate Gyrus Place Cells and Dentate Spikes during Spatial and Nonspatial Changes in Environments.Journal: The Journal of neuroscience : the official journal of the Society for NeuroscienceIn common: CircStat, EEGLAB, Signal Processing Toolbox, 1 other tool
- [9] doi:10.1038/s41593-026-02357-2 [code]
- Experience reorganizes content-specific memory traces in macaques.Journal: Nature neuroscienceIn common: CircStat, EEGLAB, Signal Processing Toolbox, 1 other tool
- [10] doi:10.1038/s41467-026-75347-4 [code]
- Sleep reveals dynamics integrating and segregating movement and stimulus representations in V1.Journal: Nature communicationsIn common: CircStat, EEGLAB, Signal Processing Toolbox, 1 other tool
Contribute
The authors of this paper can claim it, correct its record and validate its tracing map, and the maintainers of its code (its owner, or a public member of its organization) correct what it says of their repository; anyone signed in can ask for its removal. Every request goes to OSCR's own machine, which answers it; your account page follows them.
Sign in with ORCID to claim this paper as one of its authors, correct its record or validate its tracing map: when the paper's metadata lists your ORCID iD, you are recognized at once. Maintainers of its code: sign in with GitHub, then claim the repository on your account page.
Claim this paper
Correct its record
Say what each link of this record is, remove the ones that are not the paper's, add the ones that are missing. The correction becomes a new version of the record, in its Versions section.
Validate its tracing map
You validate the map as this page shows it: 1 repository of the authors' code, each at its verified commit and with its license, 3 scripts, and 0 matches between paragraphs and code (see the Code and Map sections). It then receives a DOI on Zenodo, with you (your ORCID iD) and OSCR as its creators; the code itself is not deposited.
The map's fingerprint: sha256:a830234f71106e63…
Add the badge to its README
The badge links the code to this page. Copy one of these into the README of the paper's code: only you decide where it goes, and nothing is changed for you.
Markdown
[.
Discussion, reproductions, activity
Discussion: questions and error reports about this paper and its code, from signed-in readers and its authors. It opens with sign-in.
Reproductions: reports from readers who ran the authors' code: what they reproduced, with which environment, commit and data. It opens with sign-in.
Activity: what happens around this paper: new versions of its record, its map's validation, discussions and reproductions. It opens with sign-in.
