Jump to content

File:Linear regression.svg

Page contents not supported in other languages.
This is a file from the Wikimedia Commons
From Wikipedia, the free encyclopedia
    Original file (SVG file, nominally 438 × 289 pixels, file size: 71 KB)

    Summary

    Description
    Français : Un nuage de points (en bleu) peut être modélisé par une droite de régression (en rouge).
    English: Random data points and their linear regression. Created with the following Sage (http://sagemath.org) commands:
    X = RealDistribution('uniform', [-20, 60])
    
    Y = RealDistribution('gaussian', 1.5)
    
    f(x) = 3*x/20 + 5
    
    xvals = [X.get_random_element() for _ in range(100)]
    
    data = [(x, f(x) + Y.get_random_element()) for x in xvals]
    
    m, b = var('m b')
    
    g(x) = m*x + b
    
    g(x) = g(x).subs(find_fit(data, g, solution_dict=True))
    
    p = list_plot(data) + plot(g, (x, -20, 60), color='red')
    
    p.save('linear_regression.svg')
    
    Date
    Source Own work
    Author Sewaqu
    Other versions Derivative works of this file:  Sedm zakladnich nastroju zlepsovani kvality cz.svg: 
    SVG development
    InfoField
     This image was created with Sage.
     and with Inkscape.

    Licensing

    Public domain This work has been released into the public domain by its author, Sewaqu. This applies worldwide.
    In some countries this may not be legally possible; if so:
    Sewaqu grants anyone the right to use this work for any purpose, without any conditions, unless such conditions are required by law.

    Captions

    A straight line with y-intercept 5 fitted to datapoints. A scatter plot (blue) can be rendered as a linear regression (red).
    depicts<\/a>"}},"text\/plain":{"en":{"":"depicts"}}},"{\"value\":{\"entity-type\":\"item\",\"numeric-id\":1385385,\"id\":\"Q1385385\"},\"type\":\"wikibase-entityid\"}":{"text\/html":{"en":{"P180":"Extrapolation<\/a>"}},"text\/plain":{"en":{"P180":"Extrapolation"}}}}" class="wbmi-entityview-statementsGroup wbmi-entityview-statementsGroup-P180 oo-ui-layout oo-ui-panelLayout oo-ui-panelLayout-framed">
    inception<\/a>"}},"text\/plain":{"en":{"":"inception"}}},"{\"value\":{\"time\":\"+2010-11-05T00:00:00Z\",\"timezone\":0,\"before\":0,\"after\":0,\"precision\":11,\"calendarmodel\":\"http:\\\/\\\/www.wikidata.org\\\/entity\\\/Q1985727\"},\"type\":\"time\"}":{"text\/html":{"en":{"P571":"5 November 2010"}},"text\/plain":{"en":{"P571":"5 November 2010"}}}}" class="wbmi-entityview-statementsGroup wbmi-entityview-statementsGroup-P571 oo-ui-layout oo-ui-panelLayout oo-ui-panelLayout-framed">

    5 November 2010

    source of file<\/a>"}},"text\/plain":{"en":{"":"source of file"}}},"{\"value\":{\"entity-type\":\"item\",\"numeric-id\":66458942,\"id\":\"Q66458942\"},\"type\":\"wikibase-entityid\"}":{"text\/html":{"en":{"P7482":"original creation by uploader<\/a>"}},"text\/plain":{"en":{"P7482":"original creation by uploader"}}}}" class="wbmi-entityview-statementsGroup wbmi-entityview-statementsGroup-P7482 oo-ui-layout oo-ui-panelLayout oo-ui-panelLayout-framed">
    media type<\/a>"}},"text\/plain":{"en":{"":"media type"}}},"{\"value\":\"image\\\/svg+xml\",\"type\":\"string\"}":{"text\/html":{"en":{"P1163":"image\/svg+xml"}},"text\/plain":{"en":{"P1163":"image\/svg+xml"}}}}" class="wbmi-entityview-statementsGroup wbmi-entityview-statementsGroup-P1163 oo-ui-layout oo-ui-panelLayout oo-ui-panelLayout-framed">

    image/svg+xml

    File history

    Click on a date/time to view the file as it appeared at that time.

    Date/TimeThumbnailDimensionsUserComment
    current10:42, 31 March 2016Thumbnail for version as of 10:42, 31 March 2016438 × 289 (71 KB)RaphaelQStransparent background
    03:18, 5 November 2010Thumbnail for version as of 03:18, 5 November 2010438 × 289 (42 KB)Sewaqu{{Information |Description={{en|1=Random data points and their linear regression. Created with the following Sage (http://sagemath.org) commands: X = RealDistribution('uniform', [-20, 60]) Y = RealDistribution('gaussian', 1.5) f(x) = 3*x/20 + 5 xvals

    Global file usage

    The following other wikis use this file:

    View more global usage of this file.

    Metadata