Index: corfuncview/MANIFEST.IN
===================================================================
--- corfuncview/MANIFEST.IN	(revision 846f890c4ef8e20200169d368e27ab2957374d10)
+++ corfuncview/MANIFEST.IN	(revision 846f890c4ef8e20200169d368e27ab2957374d10)
@@ -0,0 +1,6 @@
+graft docs
+graft test
+include README.txt
+include license.txt
+include release_notes.txt
+include corfunc_eula.txt
Index: corfuncview/README.txt
===================================================================
--- corfuncview/README.txt	(revision 846f890c4ef8e20200169d368e27ab2957374d10)
+++ corfuncview/README.txt	(revision 846f890c4ef8e20200169d368e27ab2957374d10)
@@ -0,0 +1,43 @@
+################################################################################
+
+The SasView (formerly SansView) software was developed by the University of 
+Tennessee as part of the Distributed Data Analysis of Neutron Scattering 
+Experiments (DANSE) project funded by the US National Science Foundation. 
+
+See the license text in license.txt
+
+Copyright 2008, University of Tennessee
+
+################################################################################
+
+The set of routines that comprise this CORFUNC module were originally written 
+in 1994 at the behest of Anthony (Tony) Ryan by Thomas (Tom) Nye whilst an 
+undergraduate in Applied Mathematics at the University of Cambridge, and are 
+based on the earlier work of Gert Strobl (Universität Freiburg) and co-workers 
+in the 1980's. The polydispersity analysis was proposed later by Guy Eeckhaut 
+(ICI).
+
+The original UNIX source was ported to the Windows environment (and given 
+a Java GUI) as part of Collaborative Computational Project #13, funded by the 
+UK Biotechnology & Biological Sciences Research Council and Engineering & 
+Physical Sciences Research Council, by CCP13 Post-Doctoral workers Richard 
+Denny and Mark Shotton in 1999.
+
+The alternative Hilbert transform (volume fraction profile) analysis of 
+Trevor Crowley (Salford University) and co-workers was suggested by Stephen 
+(Steve) King (ISIS Facility). Its incorporation was started by CCP13 Post-
+Doctoral worker Matthew Rodman and finally implemented in 2004 by Steve King 
+and Damian Flannery (ISIS Facility), with help from Richard Heenan (ISIS 
+Facility).
+
+See the End User License Agreement in corfunc_eula.txt
+
+Copyright 2013, UK Science & Technology Facilities Council
+
+################################################################################
+
+CORFUNC performs correlation function analysis of one-dimensional SAXS or SANS 
+patterns, or generates a model-independent volume fraction profile from a 
+one-dimensional SANS pattern from an adsorbed layer of polymer or surfactant.
+
+################################################################################
Index: corfuncview/corfunc_eula.txt
===================================================================
--- corfuncview/corfunc_eula.txt	(revision 846f890c4ef8e20200169d368e27ab2957374d10)
+++ corfuncview/corfunc_eula.txt	(revision 846f890c4ef8e20200169d368e27ab2957374d10)
@@ -0,0 +1,134 @@
+CORFUNC MODULE END-USER LICENCE AGREEMENT
+
+Whereas, the Licensed Software has been assembled with support from the 
+Biotechnology and Biological Sciences Research Council (BBSRC) and the 
+Engineering and Physical Sciences Research Council (EPSRC) of the UK, and 
+their forebears, as part of the Collaborative Computational Project Number 13 
+(CCP13), for Fibre and Non-Crystalline Diffraction, first set up in January 
+1992. Any opinions, findings, conclusions or recommendations expressed in the 
+Licensed Software are those of the authors of the software and do not 
+necessarily reflect the views of the BBSRC or EPSRC. The Licensed Software is 
+administered by the Science and Technology Facilities Council ("STFC", 
+previously the Council for the Central Laboratory of the Research Councils or 
+CCLRC).
+
+The Licensee shall have the right to grant access to the executable modules to 
+any personnel, such as, but not limited to, employees, researchers or students 
+of the Licensee based at its address, this includes executable modules installed
+on computer systems other than at the registered site, for example portable
+computer equipment such as laptop computers. Any such additional copies of the 
+Software shall be subject to the terms and conditions of this Agreement.
+
+The Licensee shall not sell, give, disclose, lend, transfer or otherwise 
+distribute the Licensed Software to third parties except as expressly permitted 
+under this Agreement. Where not permitted to redistribute software, the Licensee
+shall immediately refer any requests for copies of the Software to STFC.
+
+The Licensee may not sublicense, distribute or transfer the Licensed Software to
+any third party, except as expressly provided under this Agreement. Any attempt
+to intentionally sublicense, distribute or transfer the Licensed Software to a
+third party, except as otherwise permitted under this Agreement, is void, and
+will automatically terminate the Licensees rights to use the Licensed 
+Software under this Agreement.
+
+The provision of any version of the Licensed Software under the terms and 
+conditions specified herein does not imply that future versions will also be 
+made available under the same terms and conditions.
+
+THIS LICENCE AGREEMENT DOES NOT EXTEND TO COMMERCIAL USE OF THE SOFTWARE. 
+SHOULD THE LICENSEE WISH TO MAKE COMMERCIAL USE OF THE SOFTWARE, THE LICENSEE 
+AGREES TO CONTACT STFC TO ARRANGE AN APPROPRIATE COMMERCIAL LICENCE FOR SUCH 
+USE. 
+
+STFC warrants that the Licensed Software will conform substantially to its 
+functional specification. Otherwise, the Licensed Software is supplied "as is" 
+without any warranty, express or implied, including, but not limited to non-
+infringement of third parties, its merchantability or fitness for a particular 
+purpose. Neither STFC nor the original authors make any further warranty as to 
+its use, performance or results that the user may obtain by using the Licensed 
+Software. STFC does not guarantee that the functions of the Licensed Software 
+will be uninterrupted or completely error-free. STFC shall use all reasonable 
+endeavours to ensure the Licensed Software contains no viruses at the time of 
+distribution. This Agreement confers no additional responsibility or obligation 
+upon STFC.
+
+Neither STFC nor the original authors are under any obligation to maintain the 
+Licensed Software or to respond to requests for information from the Licensee. 
+Nevertheless, it remains the policy of STFC to improve and update programs and 
+their documentation continuously and answer questions from users. Current 
+information is available from STFC through a website. Where additional support 
+services are required, it is suggested that they should be obtained on an 
+individual basis. Technical suggestions, comments, and suggested improvements 
+to the code are welcome, and may be sent to the indicated representative of 
+STFC.
+
+Neither Party excludes or limits its liability to the other party for death or 
+personal injury.
+
+In no event shall STFC be liable for any indirect, special, incidental or 
+consequential damages, either from the use of the Licensed Software or from any 
+results obtained using it.
+
+The Licensee shall indemnify and hold STFC harmless against all damages, 
+liability and costs of defending against any third party claim, or threat of 
+claim, against STFC arising out of the Licensees use of the Licensed Software, 
+as delivered to the Licensee.
+
+For all Licensed Software, all copyrights remain with the original authors of 
+the code and/or their employer where that software was written as employees in 
+the course of their employment, and is licensed to the Licensee from STFC under 
+the terms and conditions of the Agreement. The Licensor has made reasonable 
+efforts to ascertain ownership of the component parts of the software.
+
+IF THE SOFTWARE IS USED TO OBTAIN A RESULT AND THAT RESULT IS PUBLISHED, THE 
+LICENSEE AGREES TO ACKNOWLEDGE ITS USE IN AN APPROPRIATE CITATION ALONG WITH 
+ANY ADDITIONAL REFERENCES REQUIRED BY THE ORIGINAL AUTHORS, PERTAINING TO THOSE 
+INDIVIDUAL PROGRAMS WHERE THE USE OF THE PROGRAMS CONTRIBUTED TO AN 
+INVESTIGATION.
+
+Neither Party shall assign, transfer, sub-contract or in any other manner make 
+over to any third party the benefit or burden of this Agreement without prior 
+written consent of the other and it is agreed that such consent may be withheld 
+without giving reasons.
+
+STFC may without prejudice to any other right or remedy hereunder terminate 
+this Agreement summarily by written notice to the Licensee in the event that:
+
+- the Licensee is in breach of any of the terms hereof (if capable of remedy) 
+and fails to rectify such breach within thirty (30) days of receipt of written 
+notice from STFC requesting the Licensee so to do; or
+
+- the Licensee commences to be wound up (otherwise than for the purposes of 
+reconstruction or amalgamation) or put into administrative receivership, or 
+carries on business under a receiver for the benefit of its creditors or 
+compounds with or enters into any scheme or arrangement with any or all of its 
+creditors or if such conditions exist as are substantially equivalent in effect 
+to any of the foregoing.
+
+Upon termination of this Agreement, the Licensee shall forthwith cease to use 
+the Licensed Software and shall immediately destroy all copies of the Licensed 
+Software. Termination of this Agreement for any reason shall not affect the 
+rights of either Party hereto accrued up to the date of such termination. 
+
+The terms and conditions set out in this Agreement may only be amended or added 
+to by formal amendments issued in writing. No oral agreement shall be binding 
+on either Party to the Agreement.
+
+The Parties hereto agree that:
+
+- this Agreement alone constitutes the agreement between STFC and the Licensee 
+in relation to the use of the Licensed Software and supersedes and overrides 
+all prior discussions between the Parties, their servants and agents and all 
+conditions, warranties, guarantees, representations, proposals, quotations, 
+communications and understandings with respect to the said use (whether given 
+or made before or on the date hereof or whether oral or given in writing); and 
+
+- no modification expressed to be an amendment to this Agreement shall have any 
+effect unless made in writing and signed by an authorised officer of STFC and 
+by an authorised officer of the Licensee. 
+
+Nothing in this Agreement shall create any rights in third parties under the 
+Contracts (Rights of Third Parties) Act 1999. No variation to this Agreement 
+and no supplemental or ancillary agreement to this Agreement shall create any 
+such rights unless expressly so stated in any such agreement by the Parties/
+parties to this Agreement.
Index: corfuncview/license.txt
===================================================================
--- corfuncview/license.txt	(revision 846f890c4ef8e20200169d368e27ab2957374d10)
+++ corfuncview/license.txt	(revision 846f890c4ef8e20200169d368e27ab2957374d10)
@@ -0,0 +1,16 @@
+This software was developed by the University of Tennessee as part of the
+Distributed Data Analysis of Neutron Scattering Experiments (DANSE)
+project funded by the US National Science Foundation. 
+
+If you use this program to do productive scientific research that leads
+to publication, we ask that you acknowledge use of the program by citing
+the following paper in your publication:
+
+P. Butler, M. Doucet, G. Alina, R. Cortes Hernandez, J. Zhou, P. Kienzle,
+Jae Hie Cho, Jessica T. Tumarkin
+"SANS analysis software", to be published.
+
+See the DANSE project web site for license information:
+http://wiki.cacr.caltech.edu/danse/index.php/Main_Page
+
+copyright 2008, University of Tennessee for the DANSE project
Index: corfuncview/release_notes.txt
===================================================================
--- corfuncview/release_notes.txt	(revision 846f890c4ef8e20200169d368e27ab2957374d10)
+++ corfuncview/release_notes.txt	(revision 846f890c4ef8e20200169d368e27ab2957374d10)
@@ -0,0 +1,1 @@
+
Index: corfuncview/setup.py
===================================================================
--- corfuncview/setup.py	(revision 846f890c4ef8e20200169d368e27ab2957374d10)
+++ corfuncview/setup.py	(revision 846f890c4ef8e20200169d368e27ab2957374d10)
@@ -0,0 +1,25 @@
+"""
+     Installation script for CCP13 CORFUNC perspective for SansView
+"""
+import os
+
+from distutils.core import setup
+setup(
+    version = "1.1.0",
+    name="corfuncview",
+    description = "Corfunc perspective for SansView",
+    package_dir = {"sans":os.path.join("src", "sans"),
+                   "sans.perspectives":os.path.join("src", "sans",
+                                                    "perspectives"),
+                   "sans.perspectives.corfunc":os.path.join("src",
+                                                            "sans",
+                                                            "perspectives",
+                                                            "corfunc"),
+                   },
+    package_data={'sans.perspectives.corfunc': [os.path.join("media",
+                                                               '*')]},
+    packages = ["sans.perspectives",
+                "sans",
+                "sans.perspectives.corfunc",],
+    )
+
Index: corfuncview/src/sans/perspectives/corfunc/corfunc.py
===================================================================
--- corfuncview/src/sans/perspectives/corfunc/corfunc.py	(revision 846f890c4ef8e20200169d368e27ab2957374d10)
+++ corfuncview/src/sans/perspectives/corfunc/corfunc.py	(revision 846f890c4ef8e20200169d368e27ab2957374d10)
@@ -0,0 +1,70 @@
+################################################################################
+#SasView was developed by the University of Tennessee as part of the
+#Distributed Data Analysis of Neutron Scattering Experiments (DANSE) project 
+#funded by the US National Science Foundation.
+#copyright 2008, University of Tennessee
+################################################################################
+#The set of routines that comprise this CORFUNC module were originally written 
+#in 1994 at the behest of Anthony (Tony) Ryan by Thomas (Tom) Nye whilst an 
+#undergraduate in Applied Mathematics at the University of Cambridge, and are 
+#based on the earlier work of Gert Strobl (Universitat Freiburg) and co-workers 
+#in the 1980's. The polydispersity analysis was proposed later by Guy Eeckhaut 
+#(ICI).
+#
+#The original UNIX source was ported to the Windows environment (and given 
+#a Java GUI) as part of Collaborative Computational Project #13, funded by the 
+#UK Biotechnology & Biological Sciences Research Council and Engineering & 
+#Physical Sciences Research Council, by CCP13 Post-Doctoral workers Richard 
+#Denny and Mark Shotton in 1999.
+#
+#The alternative Hilbert transform (volume fraction profile) analysis of 
+#Trevor Crowley (Salford University) and co-workers was suggested by Stephen 
+#(Steve) King (ISIS Facility). Its incorporation was started by CCP13 Post-
+#Doctoral worker Matthew Rodman and finally implemented in 2004 by Steve King 
+#and Damian Flannery (ISIS Facility), with help from Richard Heenan (ISIS 
+#Facility).
+#
+#Copyright 2013, UK Science & Technology Facilities Council
+################################################################################
+
+"""
+This module implements correlation function analysis or calculates volume 
+fraction profiles.
+
+:author: Steve King/ISIS
+
+"""
+import sys
+import wx
+import copy
+import logging
+
+from sans.guiframe.dataFitting import Data1D
+from sans.guiframe.events import NewPlotEvent
+from sans.guiframe.events import StatusEvent
+from sans.guiframe.gui_style import GUIFRAME_ID
+from .invariant_state import Reader as reader
+from sans.dataloader.loader import Loader
+from .invariant_panel import InvariantPanel
+from sans.guiframe.plugin_base import PluginBase
+
+class Plugin(PluginBase):
+    """
+    This class defines the interface for Corfunc Plugin class
+    that can be used by the gui_manager.       
+    """
+    
+    def __init__(self, standalone=False):
+        PluginBase.__init__(self, name="Corfunc", standalone=standalone)
+        
+        #dictionary containing data name and error on dy of that data 
+#        self.err_dy = {}
+       
+        #default state objects
+        self.state_reader = None 
+        self._extensions = None
+        self.temp_state = None 
+        self.__data = None 
+       
+        # Log startup
+        logging.info("Corfunc plug-in started")
