• 设为首页
  • 点击收藏
  • 手机版
    手机扫一扫访问
    迪恩网络手机版
  • 关注官方公众号
    微信扫一扫关注
    公众号

C# Data.DoubleColumn类代码示例

原作者: [db:作者] 来自: [db:来源] 收藏 邀请

本文整理汇总了C#中Altaxo.Data.DoubleColumn的典型用法代码示例。如果您正苦于以下问题:C# Altaxo.Data.DoubleColumn类的具体用法?C# Altaxo.Data.DoubleColumn怎么用?C# Altaxo.Data.DoubleColumn使用的例子?那么恭喜您, 这里精选的类代码示例或许可以为您提供帮助。



Altaxo.Data.DoubleColumn类属于命名空间,在下文中一共展示了Altaxo.Data.DoubleColumn类的20个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于我们的系统推荐出更棒的C#代码示例。

示例1: Max

 public static Altaxo.Data.DoubleColumn Max(Altaxo.Data.DoubleColumn c1, Altaxo.Data.DoubleColumn c2)
 {
   int len = c1.m_Count<c2.m_Count ? c1.m_Count : c2.m_Count;
   Altaxo.Data.DoubleColumn c3 = new Altaxo.Data.DoubleColumn(len);
   for(int i=0;i<len;i++)
   {
     c3.m_Array[i] = System.Math.Max(c1.m_Array[i],c2.m_Array[i]);
   }
   c3.m_Count=len;
   return c3;  
 }
开发者ID:xuchuansheng,项目名称:GenXSource,代码行数:11,代码来源:DoubleColumn.cs


示例2:

		public static Altaxo.Data.DoubleColumn operator %(double c2, Altaxo.Data.DoubleColumn c1)
		{
			int len = c1._count;
			Altaxo.Data.DoubleColumn c3 = new Altaxo.Data.DoubleColumn(len);
			for (int i = 0; i < len; i++)
			{
				c3._data[i] = c2 % c1._data[i];
			}
			c3._count = len;
			return c3;
		}
开发者ID:Altaxo,项目名称:Altaxo,代码行数:11,代码来源:DoubleColumn.cs


示例3: EhView_CopyParameterNVV

    public void EhView_CopyParameterNVV()
    {
      System.Windows.Forms.DataObject dao = new System.Windows.Forms.DataObject();
      Altaxo.Data.TextColumn txt = new Altaxo.Data.TextColumn();
      Altaxo.Data.DoubleColumn col = new Altaxo.Data.DoubleColumn();
      Altaxo.Data.DoubleColumn var = new Altaxo.Data.DoubleColumn();

      for (int i = 0; i < _doc.CurrentParameters.Count; i++)
      {
        txt[i] = _doc.CurrentParameters[i].Name;
        col[i] = _doc.CurrentParameters[i].Parameter;
        var[i] = _doc.CurrentParameters[i].Variance;
      }

      Altaxo.Data.DataTable tb = new Altaxo.Data.DataTable();
      tb.DataColumns.Add(txt, "Name", Altaxo.Data.ColumnKind.V, 0);
      tb.DataColumns.Add(col, "Value", Altaxo.Data.ColumnKind.V, 0);
      tb.DataColumns.Add(var, "Variance", Altaxo.Data.ColumnKind.V, 0);
      Altaxo.Worksheet.Commands.EditCommands.WriteAsciiToClipBoardIfDataCellsSelected(
        tb, new Altaxo.Collections.AscendingIntegerCollection(),
        new Altaxo.Collections.AscendingIntegerCollection(),
        new Altaxo.Collections.AscendingIntegerCollection(),
        dao);
      System.Windows.Forms.Clipboard.SetDataObject(dao, true);
    }
开发者ID:xuchuansheng,项目名称:GenXSource,代码行数:25,代码来源:NonlinearFitController.cs


示例4: Map

		public static Altaxo.Data.DoubleColumn Map(Func<double, double, double> function, double c1, Altaxo.Data.DoubleColumn c2)
		{
			int len = c2._count;
			Altaxo.Data.DoubleColumn c3 = new Altaxo.Data.DoubleColumn(len);
			for (int i = 0; i < len; i++)
			{
				c3._data[i] = function(c1, c2._data[i]);
			}
			c3._count = len;
			return c3;
		}
开发者ID:Altaxo,项目名称:Altaxo,代码行数:11,代码来源:DoubleColumn.cs


示例5: Pow9

		public static Altaxo.Data.DoubleColumn Pow9(Altaxo.Data.DoubleColumn c1)
		{
			int len = c1._count;
			Altaxo.Data.DoubleColumn c3 = new Altaxo.Data.DoubleColumn(len);
			for (int i = 0; i < len; i++)
			{
				c3._data[i] = Altaxo.Calc.RMath.Pow9(c1._data[i]);
			}
			c3._count = len;
			return c3;
		}
开发者ID:Altaxo,项目名称:Altaxo,代码行数:11,代码来源:DoubleColumn.cs


示例6: Round

		public static Altaxo.Data.DoubleColumn Round(double c1, Altaxo.Data.DoubleColumn c2)
		{
			int len = c2._count;
			Altaxo.Data.DoubleColumn c3 = new Altaxo.Data.DoubleColumn(len);
			for (int i = 0; i < len; i++)
			{
				c3._data[i] = System.Math.Round(c1, (int)c2._data[i]);
			}
			c3._count = len;
			return c3;
		}
开发者ID:Altaxo,项目名称:Altaxo,代码行数:11,代码来源:DoubleColumn.cs


示例7:

 public static Altaxo.Data.DoubleColumn operator %(Altaxo.Data.DoubleColumn c1, double c2)
 {
   int len = c1.m_Count;
   Altaxo.Data.DoubleColumn c3 = new Altaxo.Data.DoubleColumn(len);
   for(int i=0;i<len;i++)
   {
     c3.m_Array[i] = c1.m_Array[i] % c2;
   }
   c3.m_Count=len;
   return c3;  
 }
开发者ID:xuchuansheng,项目名称:GenXSource,代码行数:11,代码来源:DoubleColumn.cs


示例8: Subtraction

    public static Altaxo.Data.DoubleColumn Subtraction(Altaxo.Data.DateTimeColumn c1, DateTime c2)
    {
      int len = c1.Count;
      Altaxo.Data.DoubleColumn c3 = new Altaxo.Data.DoubleColumn(len);
      for (int i = 0; i < len; i++)
      {
        c3.m_Array[i] = (c1.GetValueDirect(i) - c2).TotalSeconds;
      }

      c3.m_Count = len;

      return c3;
    }
开发者ID:xuchuansheng,项目名称:GenXSource,代码行数:13,代码来源:DoubleColumn.cs


示例9: Sqrt

 public static Altaxo.Data.DoubleColumn Sqrt(Altaxo.Data.DoubleColumn c1)
 {
   int len=c1.m_Count;
   Altaxo.Data.DoubleColumn c3 = new Altaxo.Data.DoubleColumn(len);
   for(int i=0;i<len;i++)
   {
     c3.m_Array[i] = System.Math.Sqrt(c1.m_Array[i]);
   }
   c3.m_Count=len;
   return c3;
 } 
开发者ID:xuchuansheng,项目名称:GenXSource,代码行数:11,代码来源:DoubleColumn.cs


示例10: Round

 public static Altaxo.Data.DoubleColumn Round(Altaxo.Data.DoubleColumn c1, int c2)
 {
   int len = c1.m_Count;
   Altaxo.Data.DoubleColumn c3 = new Altaxo.Data.DoubleColumn(len);
   for(int i=0;i<len;i++)
   {
     c3.m_Array[i] = System.Math.Round(c1.m_Array[i],c2);
   }
   c3.m_Count=len;
   return c3;  
 }
开发者ID:xuchuansheng,项目名称:GenXSource,代码行数:11,代码来源:DoubleColumn.cs


示例11: Pow

 public static Altaxo.Data.DoubleColumn Pow(double c1, Altaxo.Data.DoubleColumn c2)
 {
   int len = c2.m_Count;
   Altaxo.Data.DoubleColumn c3 = new Altaxo.Data.DoubleColumn(len);
   for(int i=0;i<len;i++)
   {
     c3.m_Array[i] = System.Math.Pow(c1,c2.m_Array[i]);
   }
   c3.m_Count=len;
   return c3;  
 }
开发者ID:xuchuansheng,项目名称:GenXSource,代码行数:11,代码来源:DoubleColumn.cs


示例12: vop_Decrement

		public override bool vop_Decrement(out DataColumn c3)
		{
			int len = this._count;
			Altaxo.Data.DoubleColumn c33 = new Altaxo.Data.DoubleColumn(len);
			for (int i = 0; i < len; i++)
			{
				c33._data[i] = this._data[i] - 1;
			}
			c33._count = len;
			c3 = c33;
			return true;
		}
开发者ID:Altaxo,项目名称:Altaxo,代码行数:12,代码来源:DoubleColumn.cs


示例13: Min

		public static Altaxo.Data.DoubleColumn Min(Altaxo.Data.DoubleColumn c1, Altaxo.Data.DoubleColumn c2)
		{
			int len = c1._count < c2._count ? c1._count : c2._count;
			Altaxo.Data.DoubleColumn c3 = new Altaxo.Data.DoubleColumn(len);
			for (int i = 0; i < len; i++)
			{
				c3._data[i] = System.Math.Min(c1._data[i], c2._data[i]);
			}
			c3._count = len;
			return c3;
		}
开发者ID:Altaxo,项目名称:Altaxo,代码行数:11,代码来源:DoubleColumn.cs


示例14: Pow

		public static Altaxo.Data.DoubleColumn Pow(Altaxo.Data.DoubleColumn c1, double c2)
		{
			int len = c1._count;
			Altaxo.Data.DoubleColumn c3 = new Altaxo.Data.DoubleColumn(len);
			for (int i = 0; i < len; i++)
			{
				c3._data[i] = System.Math.Pow(c1._data[i], c2);
			}
			c3._count = len;
			return c3;
		}
开发者ID:Altaxo,项目名称:Altaxo,代码行数:11,代码来源:DoubleColumn.cs


示例15: Tanh

		public static Altaxo.Data.DoubleColumn Tanh(Altaxo.Data.DoubleColumn c1)
		{
			int len = c1._count;
			Altaxo.Data.DoubleColumn c3 = new Altaxo.Data.DoubleColumn(len);
			for (int i = 0; i < len; i++)
			{
				c3._data[i] = System.Math.Tanh(c1._data[i]);
			}
			c3._count = len;
			return c3;
		}
开发者ID:Altaxo,项目名称:Altaxo,代码行数:11,代码来源:DoubleColumn.cs


示例16: vop_ShiftRight_Rev

		public override bool vop_ShiftRight_Rev(DataColumn c2, out DataColumn c3)
		{
			if (c2 is Altaxo.Data.DoubleColumn)
			{
				Altaxo.Data.DoubleColumn c1 = this;
				DoubleColumn c22 = (DoubleColumn)c2;
				int len = c1.Count < c2.Count ? c1.Count : c2.Count;
				Altaxo.Data.DoubleColumn c33 = new Altaxo.Data.DoubleColumn(len);
				for (int i = 0; i < len; i++)
				{
					c33._data[i] = ((long)c22._data[i]) >> ((int)c1._data[i]);
				}
				c33._count = len;
				c3 = c33;
				return true;
			}
			c3 = null;
			return false;
		}
开发者ID:Altaxo,项目名称:Altaxo,代码行数:19,代码来源:DoubleColumn.cs


示例17: Subtraction

		public static Altaxo.Data.DoubleColumn Subtraction(DateTime c1, Altaxo.Data.DateTimeColumn c2)
		{
			int len = c2.Count;
			Altaxo.Data.DoubleColumn c3 = new Altaxo.Data.DoubleColumn(len);
			for (int i = 0; i < len; i++)
			{
				c3._data[i] = (c1 - c2.GetValueDirect(i)).TotalSeconds;
			}

			c3._count = len;

			return c3;
		}
开发者ID:Altaxo,项目名称:Altaxo,代码行数:13,代码来源:DoubleColumn.cs


示例18: ShowImportImageDialog

		/// <summary>
		/// Asks for a file name of an image file, and imports the image data into a data table.
		/// </summary>
		/// <param name="table">The table to import to.</param>
		public static void ShowImportImageDialog(this DataTable table)
		{
			ColorAmplitudeFunction colorfunc;
			var options = new Altaxo.Gui.OpenFileOptions();
			options.AddFilter("*.bmp;*.jpg;*.png,*.tif", "Image files (*.bmp;*.jpg;*.png,*.tif)");
			options.AddFilter("*.*", "All files (*.*)");
			options.FilterIndex = 0;
			options.RestoreDirectory = true;

			if (Current.Gui.ShowOpenFileDialog(options))
			{
				using (Stream myStream = new FileStream(options.FileName, FileMode.Open, FileAccess.Read, FileShare.Read))
				{
					System.Drawing.Bitmap bmp = new System.Drawing.Bitmap(myStream);

					int sizex = bmp.Width;
					int sizey = bmp.Height;
					//if(Format16bppGrayScale==bmp.PixelFormat)

					colorfunc = new ColorAmplitudeFunction(ColorToBrightness);
					// add here other function or the result of a dialog box

					// now add new columns to the worksheet,
					// the name of the columns should preferabbly simply
					// the index in x direction

					using (var suspendToken = table.SuspendGetToken())
					{
						for (int i = 0; i < sizex; i++)
						{
							Altaxo.Data.DoubleColumn dblcol = new Altaxo.Data.DoubleColumn();
							for (int j = sizey - 1; j >= 0; j--)
								dblcol[j] = colorfunc(bmp.GetPixel(i, j));

							table.DataColumns.Add(dblcol, table.DataColumns.FindUniqueColumnName(i.ToString())); // Spalte hinzufügen
						} // end for all x coordinaates

						suspendToken.Dispose();
					}
					myStream.Close();
				} // end using myStream
			}
		}
开发者ID:Altaxo,项目名称:Altaxo,代码行数:47,代码来源:FileCommands.cs


示例19: ImportImage

    public static void ImportImage(Altaxo.Data.DataTable table)
    {
      ColorAmplitudeFunction colorfunc;
      System.IO.Stream myStream;
      OpenFileDialog openFileDialog1 = new OpenFileDialog();

      openFileDialog1.InitialDirectory = "c:\\" ;
      openFileDialog1.Filter = "Image files (*.bmp;*.jpg;*.png,*.tif)|*.bmp;*.jpg;*.png,*.tif|All files (*.*)|*.*";
      openFileDialog1.FilterIndex = 1 ;
      openFileDialog1.RestoreDirectory = true ;

      if(openFileDialog1.ShowDialog() == DialogResult.OK)
      {
        if((myStream = openFileDialog1.OpenFile())!= null)
        {
          System.Drawing.Bitmap bmp = new System.Drawing.Bitmap(myStream);

          int sizex = bmp.Width;
          int sizey = bmp.Height;
          //if(Format16bppGrayScale==bmp.PixelFormat)
          
          colorfunc = new ColorAmplitudeFunction(ColorToBrightness);
          // add here other function or the result of a dialog box
  
          // now add new columns to the worksheet, 
          // the name of the columns should preferabbly simply
          // the index in x direction

          table.Suspend();
          for(int i=0;i<sizex;i++)
          {
            Altaxo.Data.DoubleColumn dblcol = new Altaxo.Data.DoubleColumn();
            for(int j=sizey-1;j>=0;j--)
              dblcol[j] = colorfunc(bmp.GetPixel(i,j));

            table.DataColumns.Add(dblcol,table.DataColumns.FindUniqueColumnName(i.ToString())); // Spalte hinzufügen
          } // end for all x coordinaates

          table.Resume();

          myStream.Close();
          myStream=null;
        } // end if myStream was != null
      } 
    }
开发者ID:xuchuansheng,项目名称:GenXSource,代码行数:45,代码来源:FileCommands.cs


示例20: IEEERemainder

 public static Altaxo.Data.DoubleColumn IEEERemainder(Altaxo.Data.DoubleColumn c1, double c2)
 {
   int len = c1.m_Count;
   Altaxo.Data.DoubleColumn c3 = new Altaxo.Data.DoubleColumn(len);
   for(int i=0;i<len;i++)
   {
     c3.m_Array[i] = System.Math.IEEERemainder(c1.m_Array[i],c2);
   }
   c3.m_Count=len;
   return c3;  
 }
开发者ID:xuchuansheng,项目名称:GenXSource,代码行数:11,代码来源:DoubleColumn.cs



注:本文中的Altaxo.Data.DoubleColumn类示例整理自Github/MSDocs等源码及文档管理平台,相关代码片段筛选自各路编程大神贡献的开源项目,源码版权归原作者所有,传播和使用请参考对应项目的License;未经允许,请勿转载。


鲜花

握手

雷人

路过

鸡蛋
该文章已有0人参与评论

请发表评论

全部评论

专题导读
上一篇:
C# Altova类代码示例发布时间:2022-05-24
下一篇:
C# Altaxo类代码示例发布时间:2022-05-24
热门推荐
阅读排行榜

扫描微信二维码

查看手机版网站

随时了解更新最新资讯

139-2527-9053

在线客服(服务时间 9:00~18:00)

在线QQ客服
地址:深圳市南山区西丽大学城创智工业园
电邮:jeky_zhao#qq.com
移动电话:139-2527-9053

Powered by 互联科技 X3.4© 2001-2213 极客世界.|Sitemap