Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
30 commits
Select commit Hold shift + click to select a range
abbbaa7
SMPlot: Change protein: to transcript: in description
nbollis May 7, 2026
3d9a505
SMPlot: Abbreviated Ion Labels
nbollis May 7, 2026
61032ee
Select and deselect all descriptors
nbollis May 7, 2026
5e93055
No replotting if we are only exporting a single plot
nbollis May 7, 2026
ff077b6
Load Rna Mods
nbollis May 7, 2026
a450353
Adjust Legend Spacing
nbollis May 7, 2026
e6c9633
try catch plot generation
nbollis May 7, 2026
2c423c4
osm mod output
nbollis May 7, 2026
44d0ff6
Test Coverage
nbollis May 7, 2026
c3ef46f
fix test
nbollis May 11, 2026
75bb1f6
MzLib 1.0.578 (#2646)
nbollis May 11, 2026
c5e8f56
Merge branch 'master' into metadraw_RNA_tweaks
nbollis May 11, 2026
a5a01fd
Merge branch 'master' into metadraw_RNA_tweaks
nbollis May 11, 2026
303b288
NonParallelizable
nbollis May 12, 2026
0a3076e
initial commit
nbollis May 13, 2026
dac375f
pre change
nbollis May 13, 2026
58f5634
draft
nbollis May 13, 2026
b025eb4
revise 1
nbollis May 14, 2026
8744b75
fix: mirror plot envelope intensities, bottom properties Y offset, se…
nbollis May 14, 2026
a48d8bf
feat: relative intensity normalization mode for mirror plot
nbollis May 14, 2026
0866a7e
fixes
nbollis May 14, 2026
94cb1d2
fixes
nbollis May 14, 2026
bf6c5e7
test: mark RNA mirror plot generator explicit
nbollis May 18, 2026
5bb90d3
fix: preserve internal ion metadata in mirror plots
nbollis May 18, 2026
80c2c99
fix: normalize mirrored isotopic envelopes
nbollis May 18, 2026
fd80e79
fix: export the full mirror plot view
nbollis May 18, 2026
bcbb4ca
fix: refresh mirror sequences with settings
nbollis May 18, 2026
bc06484
Merge branch 'master' into mirror
nbollis May 20, 2026
6c626a4
more things in table
nbollis Jul 3, 2026
eebade4
Merge branch 'mirror' of https://github.com/nbollis/MetaMorpheus into…
nbollis Jul 3, 2026
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
10 changes: 10 additions & 0 deletions .omo/run-continuation/ses_11f53df9effeMffN1QwBnnQeDL.json
Original file line number Diff line number Diff line change
@@ -0,0 +1,10 @@
{
"sessionID": "ses_11f53df9effeMffN1QwBnnQeDL",
"updatedAt": "2026-06-19T16:47:34.897Z",
"sources": {
"background-task": {
"state": "idle",
"updatedAt": "2026-06-19T16:47:34.897Z"
}
}
}
9 changes: 8 additions & 1 deletion MetaMorpheus/GUI/MetaDraw/MetaDraw.xaml
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
<Window x:Class="MetaMorpheusGUI.MetaDraw"
<Window x:Class="MetaMorpheusGUI.MetaDraw"
x:Name="MetaDrawWindow"
xmlns="http://schemas.microsoft.com/winfx/2006/xaml/presentation"
xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml"
Expand Down Expand Up @@ -704,6 +704,13 @@
<local:ChimeraAnalysisTabView x:Name="ChimeraAnalysisTabView" />
</TabItem>

<!-- Mirror Plot tab -->
<TabItem Header="{Binding TabHeader}" IsEnabled="{Binding IsTabEnabled}" Background="DarkGray"
d:DataContext="{d:DesignInstance metaDraw:MirrorPlotTabViewModel, IsDesignTimeCreatable=True}"
DataContext="{Binding MirrorPlotTabViewModel, RelativeSource={RelativeSource AncestorType=Window}}">
<local:MirrorPlotTabView x:Name="MirrorPlotTabView" />
</TabItem>

<!--Deconvolution Exploration tab-->
<TabItem Header="{Binding TabHeader}" IsEnabled="{Binding IsTabEnabled}" Background="DarkGray"
d:DataContext="{d:DesignInstance guiFunctions:DeconExplorationTabViewModel, IsDesignTimeCreatable=True}"
Expand Down
53 changes: 37 additions & 16 deletions MetaMorpheus/GUI/MetaDraw/MetaDraw.xaml.cs
Original file line number Diff line number Diff line change
Expand Up @@ -44,6 +44,7 @@ public partial class MetaDraw : Window
private static List<string> AcceptedSpectralLibraryFormats = new List<string> { ".msp" };
private FragmentationReanalysisViewModel FragmentationReanalysisViewModel;
public ChimeraAnalysisTabViewModel ChimeraAnalysisTabViewModel { get; set; }
public MirrorPlotTabViewModel MirrorPlotTabViewModel { get; set; }
public DeconExplorationTabViewModel DeconExplorationViewModel { get; set; }
public BioPolymerTabViewModel BioPolymerTabViewModel { get; set; }

Expand All @@ -61,6 +62,7 @@ public MetaDraw(string[]? filesToLoad = null)

BioPolymerTabViewModel = new BioPolymerTabViewModel(MetaDrawLogic);
ChimeraAnalysisTabViewModel = new ChimeraAnalysisTabViewModel();
MirrorPlotTabViewModel = new MirrorPlotTabViewModel();
DeconExplorationViewModel = new DeconExplorationTabViewModel(MetaDrawLogic);

propertyView = new DataTable();
Expand Down Expand Up @@ -305,25 +307,37 @@ private void dataGridScanNums_SelectedCellsChanged(object sender, SelectedCellsC
double maxDisplayedPerRow = (int)Math.Round((UpperSequenceAnnotaiton.ActualWidth - 10) / MetaDrawSettings.AnnotatedSequenceTextSpacing, 0) + 7;
MetaDrawSettings.SequenceAnnotationSegmentPerRow = (int)Math.Floor(maxDisplayedPerRow / (double)(MetaDrawSettings.SequenceAnnotaitonResiduesPerSegment + 1));

// draw the annotated spectrum
MetaDrawLogic.DisplaySequences(stationarySequenceCanvas, scrollableSequenceCanvas, sequenceAnnotationCanvas, psm);
MetaDrawLogic.DisplaySpectrumMatch(plotView, psm, itemsControlSampleViewModel, out var errors);

// add ptm legend if desired
if (MetaDrawSettings.ShowLegend)
List<string> errors = null;
try
{
int descriptionLineCount = MetaDrawSettings.SpectrumDescription.Count(p => p.Value);
if (psm.Name.IsNotNullOrEmptyOrWhiteSpace())
// draw the annotated spectrum
MetaDrawLogic.DisplaySequences(stationarySequenceCanvas, scrollableSequenceCanvas,
sequenceAnnotationCanvas, psm);
MetaDrawLogic.DisplaySpectrumMatch(plotView, psm, itemsControlSampleViewModel, out errors);

// add ptm legend if desired
if (MetaDrawSettings.ShowLegend)
{
descriptionLineCount += (int)Math.Floor((psm.Name.Length - 20) / (double)SpectrumMatchPlot.MaxCharactersPerDescriptionLine);
int descriptionLineCount = MetaDrawSettings.SpectrumDescription.Count(p => p.Value);
if (psm.Name.IsNotNullOrEmptyOrWhiteSpace())
{
descriptionLineCount += (int)Math.Floor((psm.Name.Length - 20) /
(double)SpectrumMatchPlot
.MaxCharactersPerDescriptionLine);
}

if (psm.Accession.Length > 10)
descriptionLineCount++;
double verticalOffset = descriptionLineCount * 1.7 * MetaDrawSettings.SpectrumDescriptionFontSize;

PtmLegend = new PtmLegendViewModel(psm, verticalOffset);
ChildScanPtmLegendControl.DataContext = PtmLegend;
SequenceCoveragePtmLegendControl.DataContext = PtmLegend;
}
if (psm.Accession.Length > 10)
descriptionLineCount++;
double verticalOffset = descriptionLineCount * 1.4 * MetaDrawSettings.SpectrumDescriptionFontSize;

PtmLegend = new PtmLegendViewModel(psm, verticalOffset);
ChildScanPtmLegendControl.DataContext = PtmLegend;
SequenceCoveragePtmLegendControl.DataContext = PtmLegend;
}
catch (Exception ex)
{
MessageBox.Show("Error drawing spectrum and sequence: " + ex.Message);
}

//draw the sequence coverage if not crosslinked
Expand Down Expand Up @@ -498,6 +512,7 @@ private void RefreshPlotsAfterSettingsChange(object sender, MetaDrawSettingsChan
{
MetaDrawLogic.FilterPsms();
ChimeraAnalysisTabViewModel.ProcessChimeraData(MetaDrawLogic.FilteredListOfPsms.ToList(), MetaDrawLogic.MsDataFiles);
MirrorPlotTabViewModel.ProcessMirrorData(MetaDrawLogic.FilteredListOfPsms.ToList(), MetaDrawLogic.MsDataFiles);

foreach (var group in BioPolymerTabViewModel.AllGroups)
{
Expand All @@ -522,6 +537,11 @@ private void RefreshPlotsAfterSettingsChange(object sender, MetaDrawSettingsChan
ChimeraAnalysisTabViewModel.ChimeraSpectrumMatchPlot = new ChimeraSpectrumMatchPlot(ChimeraAnalysisTabView.ms2ChimeraPlot, selectedChimeraGroup);
ChimeraAnalysisTabViewModel.ChimeraDrawnSequence = new ChimeraDrawnSequence(ChimeraAnalysisTabView.chimeraSequenceCanvas, selectedChimeraGroup, ChimeraAnalysisTabViewModel);
}

if (MirrorPlotTabViewModel.SelectedLeftPsm != null && MirrorPlotTabViewModel.SelectedRightPsm != null)
{
MirrorPlotTabViewModel.RefreshPlot();
}
}

private async void loadFilesButton_Click(object sender, RoutedEventArgs e)
Expand Down Expand Up @@ -554,6 +574,7 @@ private async void loadFilesButton_Click(object sender, RoutedEventArgs e)
loadPsms: true,
loadLibraries: true,
chimeraTabViewModel: ChimeraAnalysisTabViewModel,
mirrorPlotTabViewModel: MirrorPlotTabViewModel,
bioPolymerTabViewModel: BioPolymerTabViewModel,
deconExplorationTabViewModel: DeconExplorationViewModel,
fragmentationReanalysisViewModel: FragmentationReanalysisViewModel);
Expand Down
51 changes: 34 additions & 17 deletions MetaMorpheus/GUI/MetaDraw/MetaDrawSettingsWindow.xaml
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,7 @@
xmlns:local="clr-namespace:MetaMorpheusGUI"
xmlns:guiFunctions="clr-namespace:GuiFunctions;assembly=GuiFunctions"
mc:Ignorable="d"
Title="Graphical Settings" Width="620" SizeToContent="Height" WindowStartupLocation="CenterScreen"
Title="Graphical Settings" Width="640" SizeToContent="Height" WindowStartupLocation="CenterScreen"
Height="500" MaxHeight="700"
d:DataContext="{x:Static guiFunctions:MetaDrawSettingsViewModel.Instance}">

Expand All @@ -30,7 +30,7 @@
<!-- main settings content -->
<Grid >
<Grid.ColumnDefinitions>
<ColumnDefinition Width="Auto" />
<ColumnDefinition Width="*" />
<ColumnDefinition Width="Auto" />
<ColumnDefinition Width="*" />
</Grid.ColumnDefinitions>
Expand Down Expand Up @@ -99,7 +99,7 @@
HorizontalAlignment="Center"
Background="Transparent"
Width="2"
Margin="20,0,0,0"/>
Margin="5, 0"/>

<!-- right column -->
<ScrollViewer Grid.Column="2" HorizontalAlignment="Stretch">
Expand Down Expand Up @@ -146,8 +146,11 @@
<CheckBox Name="SubSuperScriptedIonAnnotations"
IsChecked="{Binding SubAndSuperScriptIons}"
Content="Sub/superscripted ion annotations" Margin="5" />
<CheckBox Name="UseShortIonAnnotationsWhenPossible"
IsChecked="{Binding UseShortIonAnnotationsWhenPossible}"
Content="Use short ion names (bWaterLoss -> b-H2O)" Margin="5" />

<StackPanel Orientation="Horizontal" Margin="5 0">
<StackPanel Orientation="Horizontal" Margin="5 0">
<Label Content="Annotation text size:" Width="165" />
<local:IntegerTexBoxControl x:Name="TextSizeBox" Width="80" Height="24"
Text="{Binding AnnotatedFontSize}"
Expand Down Expand Up @@ -204,19 +207,33 @@
<local:DoubleTextBoxControl x:Name ="SpectrumDescriptionFontSizeBox" Width="80" Height="24"
VerticalContentAlignment="Center" HorizontalContentAlignment="Center" />
</StackPanel>
<ItemsControl ItemsSource="{Binding SpectrumDescriptors}">
<ItemsControl.ItemTemplate>
<DataTemplate>
<CheckBox Margin="3"
IsChecked="{Binding IsSelected, Mode=TwoWay}"
Content="{Binding DisplayName}">
<CheckBox.ToolTip>
<TextBlock Text="{Binding DisplayName, Converter={StaticResource SpectrumDescriptorToolTipConverter}}"/>
</CheckBox.ToolTip>
</CheckBox>
</DataTemplate>
</ItemsControl.ItemTemplate>
</ItemsControl>
<Grid Margin="0 3 0 0">
<ItemsControl Grid.Column="0" ItemsSource="{Binding SpectrumDescriptors}">
<ItemsControl.ItemTemplate>
<DataTemplate>
<CheckBox Margin="3"
IsChecked="{Binding IsSelected, Mode=TwoWay}"
Content="{Binding DisplayName}">
<CheckBox.ToolTip>
<TextBlock Text="{Binding DisplayName, Converter={StaticResource SpectrumDescriptorToolTipConverter}}"/>
</CheckBox.ToolTip>
</CheckBox>
</DataTemplate>
</ItemsControl.ItemTemplate>
</ItemsControl>

<StackPanel Grid.Column="0" HorizontalAlignment="Right" VerticalAlignment="Top">
<Button Content="Select All"
Width="90"
Margin="0 0 0 5"
Command="{Binding SelectAllSpectrumDescriptorsCommand}"
Style="{StaticResource MetaDrawButtonStyle}"/>
<Button Content="Deselect All"
Width="90"
Command="{Binding DeselectAllSpectrumDescriptorsCommand}"
Style="{StaticResource MetaDrawButtonStyle}"/>
</StackPanel>
</Grid>
</StackPanel>

</Expander>
Expand Down
Loading